Skip to content

Commit

Permalink
infra(unicorn): use hashbang for scripts (#2448)
Browse files Browse the repository at this point in the history
  • Loading branch information
ST-DDT authored Oct 9, 2023
1 parent a1ec929 commit 72bf57d
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 1 deletion.
1 change: 0 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ module.exports = defineConfig({
'unicorn/no-instanceof-array': 'off',
'unicorn/no-negated-condition': 'off',
'unicorn/no-object-as-default-parameter': 'off',
'unicorn/no-process-exit': 'off',
'unicorn/no-useless-switch-case': 'off',
'unicorn/no-zero-fractions': 'off',
'unicorn/numeric-separators-style': 'off',
Expand Down
2 changes: 2 additions & 0 deletions scripts/apidoc.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env node

import { generate } from './apidoc/generate';
import { initMarkdownRenderer } from './apidoc/markdown';

Expand Down
2 changes: 2 additions & 0 deletions scripts/bundle.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env node

import { buildSync } from 'esbuild';
import { globSync } from 'glob';
import { allLocales } from '../src';
Expand Down
2 changes: 2 additions & 0 deletions scripts/diff.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env node

import { existsSync } from 'node:fs';
import { argv } from 'node:process';
import { diff } from './apidoc/diff';
Expand Down
3 changes: 3 additions & 0 deletions scripts/generateLocales.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env node

/**
* This file contains a script that can be used to update the following files:
*
Expand Down Expand Up @@ -366,6 +368,7 @@ async function main(): Promise<void> {
}

main().catch((e) => {
// Workaround until top level await is available
console.error(e);
process.exit(1);
});

0 comments on commit 72bf57d

Please sign in to comment.