Skip to content

Commit

Permalink
import instead
Browse files Browse the repository at this point in the history
  • Loading branch information
markcmurphy committed Jun 21, 2024
1 parent edb5a59 commit 78dfbbc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/update-static-paths.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
run: gh auth login --with-token <<< "${{ secrets.GITHUB_TOKEN }}"

- name: Generate static paths
run: node -e "require('./update-static-paths.js').generateStaticPaths()"
run: node ./update-static-paths.js

- name: Commit and push changes
run: |
Expand Down
8 changes: 4 additions & 4 deletions update-static-paths.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const path = require('path');
const fs = require('fs');
const { Octokit } = require("@octokit/rest");
import path from 'path';
import fs from 'fs';
import { Octokit } from '@octokit/rest';

const octokit = new Octokit({
auth: process.env.GITHUB_TOKEN,
Expand Down Expand Up @@ -57,4 +57,4 @@ async function generateStaticPaths() {
}
}

module.exports = { listFiles, generateStaticPaths, findStaticPaths };
export { listFiles, generateStaticPaths, findStaticPaths };

0 comments on commit 78dfbbc

Please sign in to comment.