diff --git a/.github/workflows/generate-changelog.yml b/.github/workflows/generate-changelog.yml new file mode 100644 index 0000000..99870a1 --- /dev/null +++ b/.github/workflows/generate-changelog.yml @@ -0,0 +1,23 @@ +name: Generate Changelog + +on: + pull_request: + types: [opened, reopened, synchronize] + issue_comment: + types: [created] + +jobs: + generate-changelog: + runs-on: ubuntu-latest + permissions: + contents: read + pull-requests: write + + steps: + - uses: actions/checkout@v4 + + - name: Generate Changelog + uses: agritheory/test_utils/actions/generate_changelog@main + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + anthropic-api-key: ${{ secrets.ANTHROPIC_API_KEY }} diff --git a/.github/workflows/overrides.yaml b/.github/workflows/overrides.yaml index d428293..753b977 100644 --- a/.github/workflows/overrides.yaml +++ b/.github/workflows/overrides.yaml @@ -14,6 +14,6 @@ jobs: uses: actions/checkout@v4 - name: Track Overrides - uses: diamorafaela/track-overrides@main + uses: agritheory/test_utils/actions/track_overrides@main with: - github-token: ${{ secrets.GITHUB_TOKEN }} + app: cloud_storage diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index cc76bc2..74df4e5 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -4,90 +4,76 @@ fail_fast: false repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.3.0 + rev: v5.0.0 hooks: - id: trailing-whitespace files: 'cloud_storage.*' exclude: '.*json$|.*txt$|.*csv|.*md|.*svg' - id: check-yaml - id: no-commit-to-branch - args: ['--branch', 'develop'] + args: ['--branch', 'version-15', '--branch', 'version-16'] - id: check-merge-conflict - id: check-ast - id: check-json - id: check-toml - - id: check-yaml - id: debug-statements + - repo: https://github.com/codespell-project/codespell + rev: v2.4.1 + hooks: + - id: codespell + args: ["--ignore-words-list", "notin"] + exclude: 'yarn.lock|poetry.lock' + additional_dependencies: + - tomli + - repo: https://github.com/asottile/pyupgrade - rev: v3.15.2 + rev: v3.19.1 hooks: - id: pyupgrade args: ['--py310-plus'] - - repo: https://github.com/frappe/black + - repo: https://github.com/agritheory/black rev: 951ccf4d5bb0d692b457a5ebc4215d755618eb68 hooks: - id: black - - repo: https://github.com/pre-commit/mirrors-prettier - rev: v2.7.1 - hooks: - - id: prettier - types_or: [javascript, vue, scss] - # Ignore any files that might contain jinja / bundles - exclude: | - (?x)^( - .*node_modules.*| - cloud_storage/public/dist/.*| - cloud_storage/public/js/lib/.*| - cloud_storage/templates/includes/.* - )$ - - - repo: https://github.com/pre-commit/mirrors-eslint - rev: v8.44.0 - hooks: - - id: eslint - types_or: [javascript] - args: ['--quiet'] - # Ignore any files that might contain jinja / bundles - exclude: | - (?x)^( - .*node_modules.*| - cloud_storage/public/dist/.*| - cloud_storage/public/js/lib/.*| - cloud_storage/templates/includes/.* - )$ - - - repo: https://github.com/PyCQA/isort - rev: 5.13.2 - hooks: - - id: isort - - repo: https://github.com/PyCQA/flake8 - rev: 6.0.0 + rev: 7.2.0 hooks: - id: flake8 additional_dependencies: ['flake8-bugbear'] - - repo: https://github.com/codespell-project/codespell - rev: v2.3.0 - hooks: - - id: codespell - additional_dependencies: - - tomli - - repo: https://github.com/agritheory/test_utils - rev: v1.3.2 + rev: v1.15.4 hooks: - id: update_pre_commit_config + - id: validate_frappe_project - id: validate_copyright files: '\.(js|ts|py|md)$' args: ['--app', 'cloud_storage'] + - id: bylines + exclude: 'README.md|CHANGELOG.md' - id: clean_customized_doctypes args: ['--app', 'cloud_storage'] - id: validate_customizations - # - id: validate_javascript_dependencies + - id: patch_linters + args: ['--app', 'cloud_storage'] + - id: track_overrides + args: ['--directory', '.', '--app', 'cloud_storage', '--base-branch', 'version-15'] + + - repo: https://github.com/pre-commit/mirrors-prettier + rev: v3.1.0 + hooks: + - id: prettier + types_or: [javascript, vue, scss] + exclude: | + (?x)^( + .*node_modules.*| + cloud_storage/public/dist/.*| + cloud_storage/public/js/lib/.*| + cloud_storage/templates/includes/.* + )$ ci: autoupdate_schedule: weekly diff --git a/cloud_storage/cloud_storage/custom/file.json b/cloud_storage/cloud_storage/custom/file.json index 2ecf682..2e6e7bf 100644 --- a/cloud_storage/cloud_storage/custom/file.json +++ b/cloud_storage/cloud_storage/custom/file.json @@ -1,324 +1,271 @@ { - "custom_fields": [ - { - "allow_in_quick_entry": 0, - "allow_on_submit": 0, - "bold": 0, - "collapsible": 0, - "columns": 0, - "creation": "2023-03-20 12:48:48.360631", - "default": null, - "docstatus": 0, - "dt": "File", - "fetch_if_empty": 0, - "fieldname": "file_association", - "fieldtype": "Table", - "hidden": 0, - "hide_border": 0, - "hide_days": 0, - "hide_seconds": 0, - "idx": 28, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_global_search": 0, - "in_list_view": 0, - "in_preview": 0, - "in_standard_filter": 0, - "insert_after": "section_break_1lqhx", - "is_system_generated": 0, - "is_virtual": 0, - "label": "", - "length": 0, - "modified": "2024-08-12 12:17:11.524358", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-file_association", - "no_copy": 0, - "non_negative": 0, - "options": "File Association", - "owner": "Administrator", - "permlevel": 0, - "precision": "", - "print_hide": 0, - "print_hide_if_no_value": 0, - "read_only": 0, - "report_hide": 0, - "reqd": 0, - "search_index": 0, - "show_dashboard": 0, - "sort_options": 0, - "translatable": 0, - "unique": 0 - }, - { - "allow_in_quick_entry": 0, - "allow_on_submit": 0, - "bold": 0, - "collapsible": 0, - "columns": 0, - "creation": "2023-02-03 12:03:51.204553", - "default": null, - "docstatus": 0, - "dt": "File", - "fetch_if_empty": 0, - "fieldname": "s3_key", - "fieldtype": "Data", - "hidden": 0, - "hide_border": 0, - "hide_days": 0, - "hide_seconds": 0, - "idx": 25, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_global_search": 0, - "in_list_view": 0, - "in_preview": 0, - "in_standard_filter": 0, - "insert_after": "uploaded_to_google_drive", - "is_system_generated": 0, - "is_virtual": 0, - "label": "S3 Key", - "length": 300, - "modified": "2024-08-12 12:17:11.524307", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-s3_key", - "no_copy": 0, - "non_negative": 0, - "owner": "Administrator", - "permlevel": 0, - "precision": "", - "print_hide": 0, - "print_hide_if_no_value": 0, - "read_only": 1, - "report_hide": 0, - "reqd": 0, - "search_index": 0, - "show_dashboard": 0, - "sort_options": 0, - "translatable": 0, - "unique": 0 - }, - { - "allow_in_quick_entry": 0, - "allow_on_submit": 0, - "bold": 0, - "collapsible": 0, - "columns": 0, - "creation": "2023-03-20 12:48:48.264679", - "default": null, - "docstatus": 0, - "dt": "File", - "fetch_if_empty": 0, - "fieldname": "section_break_1lqhx", - "fieldtype": "Section Break", - "hidden": 0, - "hide_border": 0, - "hide_days": 0, - "hide_seconds": 0, - "idx": 27, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_global_search": 0, - "in_list_view": 0, - "in_preview": 0, - "in_standard_filter": 0, - "insert_after": "sharing_link", - "is_system_generated": 0, - "is_virtual": 0, - "length": 0, - "modified": "2024-08-12 12:17:11.524352", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-section_break_1lqhx", - "no_copy": 0, - "non_negative": 0, - "owner": "Administrator", - "permlevel": 0, - "precision": "", - "print_hide": 0, - "print_hide_if_no_value": 0, - "read_only": 0, - "report_hide": 0, - "reqd": 0, - "search_index": 0, - "show_dashboard": 0, - "sort_options": 0, - "translatable": 0, - "unique": 0 - }, - { - "allow_in_quick_entry": 0, - "allow_on_submit": 0, - "bold": 0, - "collapsible": 0, - "columns": 0, - "creation": "2023-02-15 14:00:22.073075", - "default": null, - "docstatus": 0, - "dt": "File", - "fetch_if_empty": 0, - "fieldname": "sharing_link", - "fieldtype": "Data", - "hidden": 0, - "hide_border": 0, - "hide_days": 0, - "hide_seconds": 0, - "idx": 26, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_global_search": 0, - "in_list_view": 0, - "in_preview": 0, - "in_standard_filter": 0, - "insert_after": "s3_key", - "is_system_generated": 0, - "is_virtual": 0, - "label": "Sharing Link", - "length": 0, - "modified": "2024-08-12 12:17:11.524344", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-sharing_link", - "no_copy": 0, - "non_negative": 0, - "owner": "Administrator", - "permlevel": 0, - "precision": "", - "print_hide": 0, - "print_hide_if_no_value": 0, - "read_only": 1, - "report_hide": 0, - "reqd": 0, - "search_index": 0, - "show_dashboard": 0, - "sort_options": 0, - "translatable": 1, - "unique": 0 - }, - { - "allow_in_quick_entry": 0, - "allow_on_submit": 0, - "bold": 0, - "collapsible": 0, - "columns": 0, - "creation": "2025-06-25 21:56:21.419234", - "default": null, - "docstatus": 0, - "dt": "File", - "fetch_if_empty": 0, - "fieldname": "versions", - "fieldtype": "Table", - "hidden": 0, - "hide_border": 0, - "hide_days": 0, - "hide_seconds": 0, - "idx": 29, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_global_search": 0, - "in_list_view": 0, - "in_preview": 0, - "in_standard_filter": 0, - "insert_after": "file_association", - "is_system_generated": 0, - "is_virtual": 0, - "label": "Versions", - "length": 0, - "modified": "2025-06-30 16:53:45.299821", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-versions", - "no_copy": 0, - "non_negative": 0, - "options": "File Version", - "owner": "Administrator", - "permlevel": 0, - "precision": "", - "print_hide": 0, - "print_hide_if_no_value": 0, - "read_only": 0, - "report_hide": 0, - "reqd": 0, - "search_index": 0, - "show_dashboard": 0, - "sort_options": 0, - "translatable": 0, - "unique": 0 - } - ], - "custom_perms": [], - "doctype": "File", - "links": [], - "property_setters": [ - { - "creation": "2023-04-28 00:05:56.491129", - "doc_type": "File", - "docstatus": 0, - "doctype_or_field": "DocField", - "field_name": "preview", - "idx": 0, - "is_system_generated": 0, - "modified": "2025-06-25 21:50:10.820770", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-preview-collapsible", - "owner": "Administrator", - "property": "collapsible", - "property_type": "Check", - "value": "1" - }, - { - "creation": "2023-04-28 00:05:56.481095", - "doc_type": "File", - "docstatus": 0, - "doctype_or_field": "DocField", - "field_name": "preview", - "idx": 0, - "is_system_generated": 0, - "modified": "2025-06-25 21:50:10.827762", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-preview-collapsible_depends_on", - "owner": "Administrator", - "property": "collapsible_depends_on", - "property_type": "Data", - "value": "eval:true" - }, - { - "creation": "2023-04-28 00:05:56.507961", - "doc_type": "File", - "docstatus": 0, - "doctype_or_field": "DocField", - "field_name": "section_break_8", - "idx": 0, - "is_system_generated": 0, - "modified": "2025-06-25 21:50:10.742797", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-section_break_8-label", - "owner": "Administrator", - "property": "label", - "property_type": "Data", - "value": "Storage Details" - }, - { - "creation": "2023-04-28 00:05:56.499487", - "doc_type": "File", - "docstatus": 0, - "doctype_or_field": "DocField", - "field_name": "section_break_8", - "idx": 0, - "is_system_generated": 0, - "modified": "2025-06-25 21:50:10.814300", - "modified_by": "Administrator", - "module": "Cloud Storage", - "name": "File-section_break_8-permlevel", - "owner": "Administrator", - "property": "permlevel", - "property_type": "Int", - "value": "1" - } - ], - "sync_on_migrate": 1 + "custom_fields": [ + { + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "columns": 0, + "default": null, + "dt": "File", + "fetch_if_empty": 0, + "fieldname": "file_association", + "fieldtype": "Table", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 28, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "section_break_1lqhx", + "is_system_generated": 0, + "is_virtual": 0, + "length": 0, + "module": "Cloud Storage", + "name": "File-file_association", + "no_copy": 0, + "non_negative": 0, + "options": "File Association", + "permlevel": 0, + "print_hide": 0, + "print_hide_if_no_value": 0, + "read_only": 0, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "show_dashboard": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0 + }, + { + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "columns": 0, + "default": null, + "dt": "File", + "fetch_if_empty": 0, + "fieldname": "s3_key", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 25, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "uploaded_to_google_drive", + "is_system_generated": 0, + "is_virtual": 0, + "label": "S3 Key", + "length": 300, + "module": "Cloud Storage", + "name": "File-s3_key", + "no_copy": 0, + "non_negative": 0, + "permlevel": 0, + "print_hide": 0, + "print_hide_if_no_value": 0, + "read_only": 1, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "show_dashboard": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0 + }, + { + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "columns": 0, + "default": null, + "dt": "File", + "fetch_if_empty": 0, + "fieldname": "section_break_1lqhx", + "fieldtype": "Section Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 27, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "sharing_link", + "is_system_generated": 0, + "is_virtual": 0, + "length": 0, + "module": "Cloud Storage", + "name": "File-section_break_1lqhx", + "no_copy": 0, + "non_negative": 0, + "permlevel": 0, + "print_hide": 0, + "print_hide_if_no_value": 0, + "read_only": 0, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "show_dashboard": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0 + }, + { + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "columns": 0, + "default": null, + "dt": "File", + "fetch_if_empty": 0, + "fieldname": "sharing_link", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 26, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "s3_key", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Sharing Link", + "length": 0, + "module": "Cloud Storage", + "name": "File-sharing_link", + "no_copy": 0, + "non_negative": 0, + "permlevel": 0, + "print_hide": 0, + "print_hide_if_no_value": 0, + "read_only": 1, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "show_dashboard": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0 + }, + { + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "columns": 0, + "default": null, + "dt": "File", + "fetch_if_empty": 0, + "fieldname": "versions", + "fieldtype": "Table", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 29, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "file_association", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Versions", + "length": 0, + "module": "Cloud Storage", + "name": "File-versions", + "no_copy": 0, + "non_negative": 0, + "options": "File Version", + "permlevel": 0, + "print_hide": 0, + "print_hide_if_no_value": 0, + "read_only": 0, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "show_dashboard": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0 + } + ], + "doctype": "File", + "property_setters": [ + { + "doc_type": "File", + "doctype_or_field": "DocField", + "field_name": "preview", + "idx": 0, + "is_system_generated": 0, + "module": "Cloud Storage", + "name": "File-preview-collapsible", + "property": "collapsible", + "property_type": "Check", + "value": "1" + }, + { + "doc_type": "File", + "doctype_or_field": "DocField", + "field_name": "preview", + "idx": 0, + "is_system_generated": 0, + "module": "Cloud Storage", + "name": "File-preview-collapsible_depends_on", + "property": "collapsible_depends_on", + "property_type": "Data", + "value": "eval:true" + }, + { + "doc_type": "File", + "doctype_or_field": "DocField", + "field_name": "section_break_8", + "idx": 0, + "is_system_generated": 0, + "module": "Cloud Storage", + "name": "File-section_break_8-label", + "property": "label", + "property_type": "Data", + "value": "Storage Details" + }, + { + "doc_type": "File", + "doctype_or_field": "DocField", + "field_name": "section_break_8", + "idx": 0, + "is_system_generated": 0, + "module": "Cloud Storage", + "name": "File-section_break_8-permlevel", + "property": "permlevel", + "property_type": "Int", + "value": "1" + } + ], + "sync_on_migrate": 1 } \ No newline at end of file diff --git a/cloud_storage/cloud_storage/overrides/file.py b/cloud_storage/cloud_storage/overrides/file.py index 2959228..02d9b2c 100644 --- a/cloud_storage/cloud_storage/overrides/file.py +++ b/cloud_storage/cloud_storage/overrides/file.py @@ -22,7 +22,6 @@ from frappe.core.doctype.file.file import File, get_files_path from frappe.core.doctype.file.utils import decode_file_content, get_content_hash from frappe.model.rename_doc import rename_doc -from frappe.permissions import has_user_permission from frappe.utils import get_datetime, get_url from frappe.utils.image import optimize_image, strip_exif_data from magic import from_buffer @@ -46,12 +45,9 @@ def is_remote_file(self) -> bool: return self.file_url.startswith(URL_PREFIXES) # type: ignore return not self.content - def has_permission(self, ptype: str | None = None, user: str | None = None) -> bool: - return has_permission(self, ptype, user) - def validate(self) -> None: """ - HASH: efa6e6b66188c0131d1e374ca0904cc75f9e1119 + HASH: 69a495579a729909f4df7a45855165eee4a208f4 REPO: https://github.com/frappe/frappe PATH: frappe/core/doctype/file/file.py METHOD: validate @@ -382,32 +378,6 @@ def get_pdf_preview(self): return encoded -def has_permission(doc, ptype: str | None = None, user: str | None = None) -> bool: - """ - HASH: bfbebb3d3d9c26eb34ed447112fcd46f1dadff00 - REPO: https://github.com/frappe/frappe - PATH: frappe/core/doctype/file/file.py - METHOD: has_permission - """ - has_access = False - user = frappe.session.user if not user else user - # check if public - if doc.owner == user: - has_access = True - elif doc.attached_to_doctype and doc.attached_to_name: # type: ignore - reference_doc = frappe.get_doc(doc.attached_to_doctype, doc.attached_to_name) # type: ignore - has_access = reference_doc.has_permission() - if not has_access: - has_access = has_user_permission(doc, user) - # elif True: - # Check "shared with" including parent 'folder' to allow access - # ... - else: - has_access = bool(frappe.has_permission(doc.doctype, ptype, user=user)) - - return has_access - - def is_safe_path(path: str) -> bool: if path.startswith(URL_PREFIXES): return True diff --git a/cloud_storage/commands.py b/cloud_storage/commands.py index eb0e0d4..0aa8617 100644 --- a/cloud_storage/commands.py +++ b/cloud_storage/commands.py @@ -1,3 +1,6 @@ +# Copyright (c) 2026, AgriTheory and contributors +# For license information, please see license.txt + import click import frappe from frappe.commands import pass_context diff --git a/cloud_storage/patches/set_use_legacy_paths.py b/cloud_storage/patches/set_use_legacy_paths.py index 8a02d10..118232f 100644 --- a/cloud_storage/patches/set_use_legacy_paths.py +++ b/cloud_storage/patches/set_use_legacy_paths.py @@ -1,3 +1,6 @@ +# Copyright (c) 2026, AgriTheory and contributors +# For license information, please see license.txt + import frappe diff --git a/docs/aws-s3.md b/docs/aws-s3.md index 0df88ad..732476a 100644 --- a/docs/aws-s3.md +++ b/docs/aws-s3.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # [Amazon Web Services S3 Setup](https://aws.amazon.com/s3/) +
+ semantic-release 2025-12-05 +
+ + ## Regions The following documentation shows the available region names for AWS: diff --git a/docs/backblaze-b2.md b/docs/backblaze-b2.md index 8e37405..78fd960 100644 --- a/docs/backblaze-b2.md +++ b/docs/backblaze-b2.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # [Backblaze B2](https://www.backblaze.com/b2/cloud-storage.html) +
+ semantic-release 2025-12-05 +
+ + ## Credentials In order to generate access keys for Backblaze B2 with the following steps: diff --git a/docs/commands.md b/docs/commands.md index 094e5d4..7f93058 100644 --- a/docs/commands.md +++ b/docs/commands.md @@ -1,5 +1,13 @@ + + # Cloud Storage Migration +
+ semantic-release 2025-12-05 +
+ + This guide covers migrating existing local files to cloud storage and updating file paths to the new path strategy. ## Prerequisites diff --git a/docs/configuration.md b/docs/configuration.md index 034f678..72ced8d 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # Cloud Storage Site Configuration +
+ semantic-release 2025-12-05 +
+ + The following documentation shows how to set up some common cloud storage providers: - [Amazon Web Services S3](aws-s3.md) diff --git a/docs/decisions/0000-use-markdown-any-decision-records.md b/docs/decisions/0000-use-markdown-any-decision-records.md index 495b598..88fd619 100644 --- a/docs/decisions/0000-use-markdown-any-decision-records.md +++ b/docs/decisions/0000-use-markdown-any-decision-records.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # Use Markdown Any Decision Records +
+ semantic-release 2025-12-05 +
+ + ## Context and Problem Statement We want to record any decisions made in this project independent whether decisions concern the architecture ("architectural decision record"), the code, or other fields. diff --git a/docs/decisions/0001-no-expiry-on-public-files.md b/docs/decisions/0001-no-expiry-on-public-files.md index 2e61412..62cbb6b 100644 --- a/docs/decisions/0001-no-expiry-on-public-files.md +++ b/docs/decisions/0001-no-expiry-on-public-files.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> --- # These are optional elements. Feel free to remove any of them. + +
+ semantic-release 2025-12-05 +
+ status: proposed date: 2023-02-03 deciders: tyler@agritheory.com diff --git a/docs/decisions/0002-check-permissions-before-serving-private-file.md b/docs/decisions/0002-check-permissions-before-serving-private-file.md index cd5e7b2..4a420f4 100644 --- a/docs/decisions/0002-check-permissions-before-serving-private-file.md +++ b/docs/decisions/0002-check-permissions-before-serving-private-file.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> --- # These are optional elements. Feel free to remove any of them. + +
+ semantic-release 2025-12-05 +
+ status: proposed date: 2023-02-03 deciders: tyler@agritheory.com diff --git a/docs/decisions/adr-template.md b/docs/decisions/adr-template.md index 92a97b3..54cc140 100644 --- a/docs/decisions/adr-template.md +++ b/docs/decisions/adr-template.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> --- # These are optional elements. Feel free to remove any of them. + +
+ semantic-release 2025-12-05 +
+ status: proposed | rejected | accepted | deprecated | … | superseded by [ADR-0005](0005-example.md) date: YYYY-MM-DD when the decision was last updated deciders: list everyone involved in the decision diff --git a/docs/development.md b/docs/development.md index 9b2e4bb..fd09006 100644 --- a/docs/development.md +++ b/docs/development.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # Cloud Storage Developer Setup +
+ semantic-release 2025-12-05 +
+ + Before you begin, make sure that your Python version is: - Latest 3.10 for Frappe's version 14. diff --git a/docs/hooks.md b/docs/hooks.md index f53c161..2473999 100644 --- a/docs/hooks.md +++ b/docs/hooks.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # Cloud Storage Hooks +
+ semantic-release 2025-12-05 +
+ + ## Path Generator Hook The Cloud Storage app provides a hook to customize how file paths are generated in your S3-compatible storage bucket. diff --git a/docs/index.md b/docs/index.md index 347f6ad..7bc03d3 100644 --- a/docs/index.md +++ b/docs/index.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # Cloud Storage Documentation +
+ semantic-release 2025-12-05 +
+ + Cloud Storage extends the file utilities in a Frappe App to integrate with third-party cloud storage applications. Once configured, users can upload, download, or remove files to a cloud storage application via the Frappe App's interface. Depending on user permissions, they may also generate or reset sharing links to files. Cloud Storage can be configured to work with a variety of cloud storage providers, including Amazon Web Services S3, DigitalOcean Spaces, and Backblaze B2. diff --git a/docs/production.md b/docs/production.md index 5f625bb..24539c0 100644 --- a/docs/production.md +++ b/docs/production.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # Cloud Storage Production Setup +
+ semantic-release 2025-12-05 +
+ + Before you begin, make sure that your server's Python version is: - Latest 3.8 for Frappe's version 13 - Latest 3.10 for Frappe's version 14. diff --git a/docs/versioning.md b/docs/versioning.md index 8b7d6f5..61876df 100644 --- a/docs/versioning.md +++ b/docs/versioning.md @@ -3,6 +3,11 @@ For license information, please see license.txt--> # File Versioning and Association Logic +
+ semantic-release 2025-12-05 +
+ + ## S3/Cloud Storage Versioning Versioning must be enabled at the bucket level for S3/compatible storage. diff --git a/pyproject.toml b/pyproject.toml index d1caed0..c895de9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,13 +7,7 @@ requires-python = ">=3.10" authors = [ { name = "AgriTheory", email = "support@agritheory.dev" } ] - -[tool.poetry] -name = "cloud_storage" -version = "15.9.1" -description = "Frappe App for integrating with cloud storage applications" -authors = ["AgriTheory "] -readme = "README.md" +dynamic = ["dependencies"] [tool.poetry.dependencies] python = "^3.10" @@ -30,6 +24,9 @@ pytest-cov = "^5.0.0" requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" +[tool.bench.frappe-dependencies] +frappe = ">=15.0.0,<16.0.0" + [tool.codespell] skip = "CHANGELOG.md" @@ -49,7 +46,7 @@ ensure_newline_before_comments = true indent = "\t" [tool.semantic_release] -version_toml = ["pyproject.toml:tool.poetry.version"] +version_toml = ["pyproject.toml:project.version"] version_variable = [ "cloud_storage/__init__.py:__version__" ]