Skip to content

Commit 62f4fe6

Browse files
committed
feat: migrate from nostr-tools to applesauce and fix install script
- Remove all nostr-tools dependencies in favor of applesauce-relay/signers - Replace nip19 encoding/decoding with @scure/base bech32 functions - Remove legacy nostr-client.ts file using SimplePool - Update install script to use unversioned binaries - Update GitHub Actions to publish both versioned and unversioned assets - Fix homepage hallucination: replace 'Mesh Network Ready' with real 'Fast & Efficient' feature
1 parent 4e0a158 commit 62f4fe6

7 files changed

Lines changed: 29 additions & 389 deletions

File tree

.github/workflows/release.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,9 @@ jobs:
7575
nsyte-windows-${{ env.VERSION }}.exe
7676
```
7777
files: |
78+
dist/nsyte-linux
79+
dist/nsyte-macos
80+
dist/nsyte-windows.exe
7881
dist/nsyte-linux-${{ env.VERSION }}
7982
dist/nsyte-macos-${{ env.VERSION }}
8083
dist/nsyte-windows-${{ env.VERSION }}.exe

index.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -972,10 +972,10 @@ <h3 class="feature-title">Revocable CI/CD Keys</h3>
972972
</div>
973973

974974
<div class="feature-card">
975-
<div class="feature-icon">🕸️</div>
976-
<h3 class="feature-title">Mesh Network Ready</h3>
975+
<div class="feature-icon"></div>
976+
<h3 class="feature-title">Fast & Efficient</h3>
977977
<p class="feature-description">
978-
Built on nostr and Blossom protocols. Resilient, peer-to-peer infrastructure that routes around damage.
978+
Concurrent uploads with smart diffing. Only upload what's changed. Configure concurrency for optimal performance.
979979
</p>
980980
</div>
981981

src/commands/upload.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { colors } from "@cliffy/ansi/colors";
22
import type { Command } from "@cliffy/command";
33
import { Confirm } from "@cliffy/prompt";
4-
import { nip19 } from "npm:nostr-tools";
4+
import { npubEncode } from "../lib/utils.ts";
55
import { copy } from "std/fs/copy.ts";
66
import { join, normalize, dirname } from "std/path/mod.ts";
77
import { defaultConfig, readProjectFile, setupProject, type ProjectConfig, type ProjectContext } from "../lib/config.ts";
@@ -198,7 +198,7 @@ export async function uploadCommand( fileOrFolder: string, options_: UploadComma
198198
}
199199

200200
function displayGatewayUrl(publisherPubkey: string) {
201-
const npub = nip19.npubEncode(publisherPubkey);
201+
const npub = npubEncode(publisherPubkey);
202202
const { gatewayHostnames } = config;
203203
console.log(colors.green(`\nThe website is now available on any nsite gateway, for example:`));
204204
for (const gatewayHostname of gatewayHostnames || []) {

src/lib/nip46.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { NostrConnectSigner, SimpleSigner } from "applesauce-signers";
77
import { qrcode as generateQrCodeForTerminal } from "jsr:@libs/qrcode";
88
import { bytesToHex, hexToBytes } from "npm:@noble/hashes/utils";
99
import { bech32 } from "npm:@scure/base";
10-
import * as nostrTools from "npm:nostr-tools";
10+
import { randomBytes } from "@noble/hashes/utils";
1111
import { lastValueFrom } from "rxjs";
1212
import { createLogger } from "./logger.ts";
1313
import { SecretsManager } from "./secrets/mod.ts";
@@ -283,7 +283,7 @@ export async function saveBunkerInfo(bunkerPubkey: string, clientKey: Uint8Array
283283
*/
284284
export async function storeBunkerUrl(bunkerPubkey: string, bunkerUrl: string): Promise<void> {
285285
try {
286-
const tempClientKey = nostrTools.generateSecretKey();
286+
const tempClientKey = randomBytes(32);
287287

288288
await saveBunkerInfo(bunkerPubkey, tempClientKey, bunkerUrl);
289289

0 commit comments

Comments
 (0)