diff --git a/.github/workflows/production_release.yml b/.github/workflows/production_release.yml deleted file mode 100644 index 1c0a9b9..0000000 --- a/.github/workflows/production_release.yml +++ /dev/null @@ -1,57 +0,0 @@ -name: Promote and release Salesforce package - -on: - workflow_dispatch: - inputs: - packageID: - description: 'ID (starts with 04t) of the package version to promote' - required: true - versionNumber: - description: 'Package version to release (e.g., 1.0.1 or 1.1.0)' - required: true - -jobs: - promote-sf-package: - runs-on: ubuntu-latest - - steps: - #Install Salesforce CLI - - name: 'Install Salesforce CLI' - run: | - npm install @salesforce/cli --location=global - nodeInstallPath=$(npm config get prefix) - echo "$nodeInstallPath/bin" >> $GITHUB_PATH - sf --version - - # Checkout the source code - - name: 'Checkout source code' - uses: actions/checkout@v4 - - # Store secret for dev hub - - name: 'Populate auth file with DEV_HUB_URL secret' - shell: bash - run: | - echo ${{ secrets.DEV_HUB_AUTH_URL_URL}} > ./DEV_HUB_AUTH_URL.txt - secretFileSize=$(wc -c "./DEV_HUB_AUTH_URL.txt" | awk '{print $1}') - if [ $secretFileSize == 1 ]; then - echo "Missing DEV_HUB_AUTH_URL secret. Is this workflow running on a fork?"; - exit 1; - fi - - # Authenticate dev hub - - name: 'Authenticate Dev Hub' - run: sf org login sfdx-url -f ./DEV_HUB_AUTH_URL.txt -a devhub -d - - # Remove auth file - - name: 'Remove auth file' - run: rm -f ./DEV_HUB_AUTH_URL.txt - - # Promote Package version - - name: Run SFDX Promote command - run: sf package version promote --package ${{ github.event.inputs.packageID }} -n - - # Create release notes - - name: Create release - run: gh release create ${{ github.event.inputs.versionNumber }} --generate-notes - env: - GITHUB_TOKEN: ${{ secrets.CUMULUSCI_SERVICE_GITHUB }} \ No newline at end of file diff --git a/cumulusci.yml b/cumulusci.yml index 89968bb..db53704 100644 --- a/cumulusci.yml +++ b/cumulusci.yml @@ -2,7 +2,7 @@ minimum_cumulusci_version: '3.74.0' project: name: GrantGuides package: - name: ggw + name: Grant Content Kit namespace: GCKit api_version: '55.0' git: @@ -46,13 +46,16 @@ flows: task: command options: command: cci org default --org dev - - gk_release_beta: - description: 'Generate Release notes and auto merge main branch.' + + release_2gp_beta: steps: 1: - task: github_release - 2: - task: github_release_notes - 3: - task: github_automerge_main \ No newline at end of file + options: + package_type: Managed + package_name: $project_config.project__package__name + skip_validation: False + ancestor_id: latest_github_release + version_base: latest_github_release + version_type: major + force_upload: True + create_unlocked_dependency_packages: False diff --git a/force-app/main/default/classes/GGW_ApplicationCtrl.cls b/force-app/main/default/classes/GGW_ApplicationCtrl.cls index 97c8fb5..ada7d81 100644 --- a/force-app/main/default/classes/GGW_ApplicationCtrl.cls +++ b/force-app/main/default/classes/GGW_ApplicationCtrl.cls @@ -149,7 +149,7 @@ public with sharing class GGW_ApplicationCtrl { GGW_Selected_Item__c item = new GGW_Selected_Item__c(); item.Id = itemId; if(Schema.sObjectType.GGW_Selected_Item__c.isDeletable()){ - delete item; + delete as User item; } } @@ -326,10 +326,10 @@ public with sharing class GGW_ApplicationCtrl { ContentDocument cd = new ContentDocument(); cd.Id = cdl.ContentDocumentId; if(Schema.sObjectType.ContentDistribution.isDeletable()){ - delete cntdistr; + delete as User cntdistr; } if(Schema.sObjectType.ContentDocument.isDeletable()){ - delete cd; + delete as User cd; } } private static String getValidLogoURL(GGW_Grant_Application__c grant){ @@ -432,7 +432,7 @@ public with sharing class GGW_ApplicationCtrl { } if(!removeItems.isEmpty()){ if(Schema.sObjectType.GGW_Selected_Item__c.isDeletable()){ - delete removeItems; + delete as User removeItems; } } }