aboutsummaryrefslogtreecommitdiff
path: root/cmd/within.website
diff options
context:
space:
mode:
authorXe Iaso <me@xeiaso.net>2023-08-11 19:47:15 -0400
committerXe Iaso <me@xeiaso.net>2023-08-11 19:47:15 -0400
commit6607ca0ec6565130aaec80cc750ce5d3cde15924 (patch)
tree0e058be362304419e21ea23dd95f49ddb34c3f2a /cmd/within.website
parente50eae921dc8189f8ea34636a77d61897898f019 (diff)
downloadx-6607ca0ec6565130aaec80cc750ce5d3cde15924.tar.xz
x-6607ca0ec6565130aaec80cc750ce5d3cde15924.zip
cmd/yeet: revolutionize a few apps
Signed-off-by: Xe Iaso <me@xeiaso.net>
Diffstat (limited to 'cmd/within.website')
-rw-r--r--cmd/within.website/config.ts37
-rw-r--r--cmd/within.website/yeetfile.js7
2 files changed, 41 insertions, 3 deletions
diff --git a/cmd/within.website/config.ts b/cmd/within.website/config.ts
index e69de29..e79434d 100644
--- a/cmd/within.website/config.ts
+++ b/cmd/within.website/config.ts
@@ -0,0 +1,37 @@
+export interface Repo {
+ kind: "gitea" | "github";
+ domain: string;
+ user: string;
+ repo: string;
+ description: string;
+}
+
+const githubRepo = (name: string, description: string): Repo => {
+ return {
+ kind: "github",
+ domain: "github.com",
+ user: "Xe",
+ repo: name,
+ description,
+ };
+};
+
+const giteaRepo = (name: string, description: string): Repo => {
+ return {
+ kind: "gitea",
+ domain: "tulpa.dev",
+ user: "cadey",
+ repo: name,
+ description,
+ };
+};
+
+const repos: Repo[] = [
+ githubRepo("derpigo", "A Derpibooru/Furbooru API client in Go. This is used to monitor Derpibooru/Furbooru for images by artists I care about and archive them."),
+ githubRepo("eclier", "A command router for Go programs that implements every command in Lua. This was an experiment for making extensible command-line applications with Lua for extending them."),
+ giteaRepo("gopher", "A Gopher (RFC 1436) client/server stack for Go applications. This allows users to write custom Gopher clients and servers."),
+ githubRepo("ln", "The natural log function for Go: an easy package for structured logging. This is the logging stack that I use for most of my personal projects."),
+ githubRepo("x", "Various experimental things. /x/ is my monorepo of side projects, hobby programming, and other explorations of how programming in Go can be."),
+];
+
+export default repos;
diff --git a/cmd/within.website/yeetfile.js b/cmd/within.website/yeetfile.js
index 676443e..b79868c 100644
--- a/cmd/within.website/yeetfile.js
+++ b/cmd/within.website/yeetfile.js
@@ -1,12 +1,13 @@
yeet.setenv("GOOS", "linux");
yeet.setenv("GOARCH", "amd64");
+yeet.setenv("CGO_ENABLED", "0");
go.build();
-slug.build("within.website", {
+const fname = slug.build("within.website", {
"config.ts": "config.ts"
});
-const url = slug.push("within.website");
+const url = slug.push(fname);
const hash = nix.hashURL(url);
const expr = nix.expr`{ stdenv }:
@@ -23,7 +24,7 @@ stdenv.mkDerivation {
installPhase = ''
tar xf $src
mkdir -p $out/bin
- cp web $out/bin/withinwebsite
+ cp bin/main $out/bin/withinwebsite
cp config.ts $out/config.ts
'';
}