Skip to content

Commit

Permalink
Code review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
tmeasday committed Jun 13, 2023
1 parent dfc2351 commit 0046f76
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
3 changes: 3 additions & 0 deletions node-src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ import { writeChromaticDiagnostics } from './lib/writeChromaticDiagnostics';
import invalidPackageJson from './ui/messages/errors/invalidPackageJson';
import noPackageJson from './ui/messages/errors/noPackageJson';

/**
Make keys of `T` outside of `R` optional.
*/
type AtLeast<T, R extends keyof T> = Partial<T> & Pick<T, R>;

interface Output {
Expand Down
15 changes: 6 additions & 9 deletions scripts/run-via-node.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
import process from 'process';
import { run } from '../dist/node';

async function go() {
await run({
flags: {
projectToken: process.env.CHROMATIC_PROJECT_TOKEN,
},
});
}

go().catch((err) => {
run({
flags: {
projectToken: process.env.CHROMATIC_PROJECT_TOKEN,
},
}).catch((err) => {
// eslint-disable-next-line no-console
console.log(err);
process.exit(1);
});

0 comments on commit 0046f76

Please sign in to comment.