Skip to content

Commit

Permalink
[CD] Rename packs-json.zip to json-assets.zip and add `static/lan…
Browse files Browse the repository at this point in the history
…g` files (#8273)
  • Loading branch information
In3luki committed Jun 14, 2023
1 parent b0dfb7b commit fa01fe1
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,11 @@ jobs:
working-directory: ./dist
run: zip -r ./pf2e.zip ./*

- name: Zip JSON Packs
working-directory: ./packs-json
run: zip -r ./packs-json.zip ./*
- name: Zip JSON Assets
working-directory: ./json-assets
run: |
cp -r ../static/lang/ ./
zip -r ./json-assets.zip ./*
- name: Create Version Release
id: create_version_release
Expand All @@ -50,5 +52,5 @@ jobs:
draft: false
prerelease: false
token: ${{ secrets.GITHUB_TOKEN }}
artifacts: "./dist/system.json,./dist/pf2e.zip,./packs-json/packs-json.zip"
artifacts: "./dist/system.json,./dist/pf2e.zip,./json-assets/json-assets.zip"
tag: ${{ env.systemVersion }}
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ foundryconfig.json
node_modules/
package/
packs-temp/
packs-json/
json-assets/
types/foundry/node_modules/
types/foundry/package-lock.json

Expand Down
4 changes: 2 additions & 2 deletions build/lib/compendium-pack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -383,9 +383,9 @@ class CompendiumPack {
}

async saveAsJSON(): Promise<number> {
const outDir = path.resolve(process.cwd(), "packs-json");
const outDir = path.resolve(process.cwd(), "json-assets/packs");
if (!fs.lstatSync(outDir, { throwIfNoEntry: false })?.isDirectory()) {
fs.mkdirSync(outDir);
fs.mkdirSync(outDir, { recursive: true });
}

const outFile = path.resolve(outDir, `${this.packDir}.json`);
Expand Down

0 comments on commit fa01fe1

Please sign in to comment.