Skip to content

Commit 11a08db

Browse files
committed
Tsup to esbuild
1 parent ef9f1b5 commit 11a08db

File tree

6 files changed

+244
-2845
lines changed

6 files changed

+244
-2845
lines changed

.github/workflows/npm-publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
# Only install dev dependencies, for the binary. No need to install deps for the source code.
3030
- name: Install dependencies
3131
# Weird tsup quirk https://github.com/npm/cli/issues/4828#issuecomment-2404560937
32-
run: pnpm i @rollup/rollup-linux-x64-gnu && pnpm install --dev
32+
run: pnpm install --dev
3333
working-directory: ./examples/get-started
3434

3535
- name: Build binary

examples/get-started/bin/get-started.mjs

Lines changed: 12 additions & 670 deletions
Large diffs are not rendered by default.

examples/get-started/bin/get-started.ts

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@ import path from 'path';
66
import { fileURLToPath } from 'url';
77
import waitOn from 'wait-on';
88

9-
// @ts-ignore
10-
import packageJson from '../package.json';
11-
129
// @ts-ignore
1310
const __filename = fileURLToPath(import.meta.url);
1411
const __dirname = path.dirname(__filename);
@@ -32,15 +29,10 @@ async function main() {
3229

3330
if (projectName) {
3431
targetDir = path.join(currentDir, projectName);
35-
const filesToCopy = ['src', 'scheduleWorkflow.ts', 'tsconfig.json'];
32+
const filesToCopy = ['src', 'scheduleWorkflow.ts', 'tsconfig.json', 'package.json'];
3633
filesToCopy.forEach(file => {
3734
fs.cpSync(path.join(packageRoot, file), path.join(targetDir, file), { recursive: true });
3835
});
39-
40-
// Copy package.json separately and modify it
41-
delete packageJson.bin;
42-
delete packageJson.files;
43-
fs.writeFileSync(path.join(targetDir, 'package.json'), JSON.stringify(packageJson, null, 2));
4436
}
4537

4638
const installDependencies = (await clack.confirm({
@@ -72,7 +64,7 @@ async function main() {
7264

7365
if (openRestack) {
7466
const s = clack.spinner();
75-
s.start('Waiting for Restack Engine Studio to start');
67+
s.start('Waiting for Restack Engine Studio to be ready...');
7668
await waitOn({ resources: ['http://localhost:5233'] });
7769
s.stop();
7870
execSync('open http://localhost:5233', { stdio: 'inherit', cwd: targetDir });

0 commit comments

Comments
 (0)