🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

fangge

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fangge - npm Package Compare versions

Comparing version
1.0.3
to
1.0.4
+48
-50
dist/cli.js

@@ -79,3 +79,3 @@ #!/usr/bin/env node

};
var musicUrl = "https://www.soundhelix.com/examples/mp3/SoundHelix-Song-1.mp3";
var musicUrl = "https://archive.org/download/f7db6af68ab12dfa9894e8f6fff5e370954f6395457a5c5c00b45874a49138ec9a4b3f145fcc5e88/Super%20Mario%20Bros%20Owld.mp3";
var links = [

@@ -256,31 +256,34 @@ { label: "ListenHub", href: "https://listenhub.ai", display: "listenhub.ai" },

import { jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
var R = "#E60012";
var W = "#FFFFFF";
var S = "#FFDAB9";
var K = "#000000";
var Mascot = () => /* @__PURE__ */ jsxs5(Box4, { flexDirection: "column", width: 11, children: [
var R = "#CE2029";
var H = "#6B420C";
var S = "#E8A860";
var Mascot = () => /* @__PURE__ */ jsxs5(Box4, { flexDirection: "column", width: 12, children: [
/* @__PURE__ */ jsxs5(Text5, { children: [
" ",
/* @__PURE__ */ jsx5(Text5, { color: R, children: "\u2584\u2584\u2588\u2588\u2588\u2584\u2584" }),
" "
" ",
/* @__PURE__ */ jsx5(Text5, { color: R, children: "\u2584\u2588\u2588\u2588\u2588\u2588\u2584\u2584\u2584" }),
" "
] }),
/* @__PURE__ */ jsxs5(Text5, { children: [
/* @__PURE__ */ jsx5(Text5, { color: R, children: "\u2584\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: R, backgroundColor: R, children: "\u2580\u2580" }),
/* @__PURE__ */ jsx5(Text5, { color: R, children: "\u2588\u2588\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: R, backgroundColor: R, children: "\u2580\u2580" }),
/* @__PURE__ */ jsx5(Text5, { color: R, children: "\u2588\u2584" })
/* @__PURE__ */ jsx5(Text5, { color: H, children: "\u2584" }),
/* @__PURE__ */ jsx5(Text5, { color: H, backgroundColor: S, children: "\u2580" }),
/* @__PURE__ */ jsx5(Text5, { color: H, children: "\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: H, backgroundColor: S, children: "\u2580" }),
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2588\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: H, children: "\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2588\u2584\u2584" }),
" "
] }),
/* @__PURE__ */ jsxs5(Text5, { children: [
" ",
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: W, backgroundColor: K, children: "\u2022" }),
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2588\u2588\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: W, backgroundColor: K, children: "\u2022" }),
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2588" }),
" "
/* @__PURE__ */ jsx5(Text5, { color: H, children: "\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: S, backgroundColor: H, children: "\u2580" }),
/* @__PURE__ */ jsx5(Text5, { color: H, backgroundColor: S, children: "\u2580\u2580" }),
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2588\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: S, backgroundColor: H, children: "\u2580" }),
/* @__PURE__ */ jsx5(Text5, { color: H, children: "\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: S, backgroundColor: H, children: "\u2580\u2580" }),
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2580" })
] }),
/* @__PURE__ */ jsxs5(Text5, { children: [
" ",
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2588\u2588\u2588\u2588\u2588\u2588\u2588" }),
/* @__PURE__ */ jsx5(Text5, { color: S, children: "\u2580\u2580\u2580\u2580\u2580\u2580\u2580" }),
" "

@@ -316,31 +319,26 @@ ] })

}
const getter = url.startsWith("https") ? httpsGet : httpGet;
const file = createWriteStream(dest);
const request = getter(url, (res) => {
if (res.statusCode && res.statusCode >= 300 && res.statusCode < 400 && res.headers.location) {
const follow = (target, maxRedirects = 5) => {
const getter = target.startsWith("https") ? httpsGet : httpGet;
getter(target, (res) => {
if (res.statusCode && res.statusCode >= 300 && res.statusCode < 400 && res.headers.location && maxRedirects > 0) {
res.resume();
follow(res.headers.location, maxRedirects - 1);
return;
}
res.pipe(file);
file.on("finish", () => {
file.close();
resolve(dest);
});
}).on("error", (err) => {
file.close();
const redirectGet = res.headers.location.startsWith("https") ? httpsGet : httpGet;
redirectGet(res.headers.location, (redirectRes) => {
redirectRes.pipe(file);
file.on("finish", () => {
file.close();
resolve(dest);
});
}).on("error", reject);
return;
}
res.pipe(file);
file.on("finish", () => {
file.close();
resolve(dest);
try {
unlinkSync(dest);
} catch {
}
reject(err);
});
});
request.on("error", (err) => {
file.close();
try {
unlinkSync(dest);
} catch {
}
reject(err);
});
};
follow(url);
}),

@@ -465,3 +463,2 @@ [url]

] }),
/* @__PURE__ */ jsx6(MusicPlayer, { status: audio.status }),
/* @__PURE__ */ jsx6(Experience, { experiences }),

@@ -482,3 +479,4 @@ /* @__PURE__ */ jsx6(Projects, { projects }),

] }),
/* @__PURE__ */ jsx6(Links, { links })
/* @__PURE__ */ jsx6(Links, { links }),
/* @__PURE__ */ jsx6(MusicPlayer, { status: audio.status })
]

@@ -485,0 +483,0 @@ }

{
"name": "fangge",
"version": "1.0.3",
"version": "1.0.4",
"description": "Fango's terminal business card — run npx fango",

@@ -5,0 +5,0 @@ "type": "module",