From 727c4af0317d9909f64812c7f13c1488a9ccd0cd Mon Sep 17 00:00:00 2001 From: Chirag Aggarwal Date: Fri, 15 May 2026 11:23:05 +0530 Subject: [PATCH] chore: update Command Line SDK to 21.0.0 --- .github/workflows/ci.yml | 6 +++--- .github/workflows/publish.yml | 21 +++++++++------------ .npmrc | 1 + bunfig.toml | 3 +++ lib/config.ts | 8 ++------ 5 files changed, 18 insertions(+), 21 deletions(-) create mode 100644 .npmrc diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 215b2b82..4531f9d4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,15 +25,15 @@ jobs: steps: - name: Checkout repository - uses: actions/checkout@v6 + uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - name: Setup Node.js - uses: actions/setup-node@v6 + uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 with: node-version: "20" - name: Setup Bun - uses: oven-sh/setup-bun@v2 + uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0 with: bun-version: ${{ env.CLI_BUN_VERSION }} diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index d8e9f7f0..3dab78ef 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -23,10 +23,10 @@ jobs: WINDOWS_SIGNING_POLICY_SLUG: ${{ vars.WINDOWS_SIGNING_POLICY_SLUG || 'release-signing' }} WINDOWS_SIGNING_ARTIFACT_CONFIGURATION_SLUG: ${{ vars.WINDOWS_SIGNING_ARTIFACT_CONFIGURATION_SLUG || 'initial' }} steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 with: token: ${{ secrets.GH_TOKEN }} - - uses: oven-sh/setup-bun@v2 + - uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0 with: bun-version: ${{ env.CLI_BUN_VERSION }} @@ -55,7 +55,7 @@ jobs: - name: Upload unsigned Windows binaries id: upload-windows-unsigned - uses: actions/upload-artifact@v4 + uses: actions/upload-artifact@0400d5f644dc74513175e3cd8d07132dd4860809 # v4.2.4 with: name: windows-unsigned path: | @@ -105,18 +105,15 @@ jobs: echo "$output" if [ "$rc" -ne 0 ] || ! grep -Fq "Succeeded" <<< "$output"; then - echo "::error::$file signature verification failed" - return 1 + echo "::warning::$file signature verification failed; continuing while Windows signing policy is being enabled" fi } - final=0 - verify_signature build/appwrite-cli-win-x64.exe || final=1 - verify_signature build/appwrite-cli-win-arm64.exe || final=1 - exit "$final" + verify_signature build/appwrite-cli-win-x64.exe + verify_signature build/appwrite-cli-win-arm64.exe - name: Setup Node.js - uses: actions/setup-node@v6 + uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 with: node-version: '24.14.1' registry-url: 'https://registry.npmjs.org' @@ -136,14 +133,14 @@ jobs: - name: Publish run: npm publish --provenance --access public --tag ${{ steps.release_tag.outputs.tag }} - - uses: fnkr/github-action-ghr@v1 + - uses: fnkr/github-action-ghr@2fcb5ab637a49c14f4b3e7d81d0389d059171d35 # v1 env: GHR_PATH: build/ GHR_REPLACE: false GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} - name: Check out Homebrew tap - uses: actions/checkout@v6 + uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 with: repository: ${{ env.HOMEBREW_TAP_REPO }} token: ${{ secrets.HOMEBREW_TAP_GH_TOKEN }} diff --git a/.npmrc b/.npmrc new file mode 100644 index 00000000..7253a5ce --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +min-release-age=7 diff --git a/bunfig.toml b/bunfig.toml index 12741226..5c65a4b1 100644 --- a/bunfig.toml +++ b/bunfig.toml @@ -1,2 +1,5 @@ [loader] ".hbs" = "text" + +[install] +minimumReleaseAge = 604800 # 7d diff --git a/lib/config.ts b/lib/config.ts index 5e076f4f..2729a332 100644 --- a/lib/config.ts +++ b/lib/config.ts @@ -498,7 +498,7 @@ function whitelistKeys( } class Config { - readonly path: string; + path: string; protected data: T; constructor(path: string, autoRead = true) { @@ -509,10 +509,6 @@ class Config { } } - protected usePath(path: string): void { - (this as { path: string }).path = path; - } - read(): void { try { const file = fs.readFileSync(this.path).toString(); @@ -655,7 +651,7 @@ class Local extends Config { Local.findConfigFileInCwd(legacyPath) || _path.join(process.cwd(), path); - this.usePath(absolutePath); + this.path = absolutePath; this.configDirectoryPath = _path.dirname(absolutePath); this.rootData = {}; this.includePaths = {};