Skip to content

Commit

Permalink
Merge pull request #9 from kodadot/vikiival-patch-1
Browse files Browse the repository at this point in the history
Skip chain if file is not present
  • Loading branch information
vikiival authored Sep 4, 2024
2 parents 9568620 + 7689b77 commit 98af3f6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/search-updater.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ jobs:
run: |
deno task start
- name: Execute changes
if: ${{ hashFiles(${{ matrix.chain }}.sql) != '' }}
if: ${{ hashFiles(${{ matrix.chain }}) != '' }}
uses: cloudflare/[email protected]
with:
apiToken: ${{ secrets.CF_API_TOKEN }}
accountId: ${{ secrets.CF_ACCOUNT_ID }}
workingDirectory: "polysearch"
command: d1 execute search --file=./${{ matrix.chain }}.sql
command: d1 execute search --file=./${{ matrix.chain }}
2 changes: 1 addition & 1 deletion polysearch/sql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ export const sqlToString = (statement: Sql): string => {
};

export const saveStatement = async (statement: Sql) => {
await Deno.writeTextFile(`./${CHAIN}.sql`, statement.toString());
await Deno.writeTextFile(`./${CHAIN}`, statement.toString());
};

0 comments on commit 98af3f6

Please sign in to comment.