dev container and git config

This commit is contained in:
2026-10-09 06:19:05 +02:00
parent 596b5873e6
commit 99422bc415
3 changed files with 35 additions and 5 deletions
+5 -1
View File
@@ -40,7 +40,11 @@ function dev
alsa-lib-devel \ alsa-lib-devel \
systemd-devel \ systemd-devel \
libxkbcommon \ libxkbcommon \
libxkbcommon-devel libxkbcommon-devel \
libappindicator-gtk3-devel \
librsvg2-devel \
libxdo-devel \
nodejs24
if distrobox list --no-color | string match -q "*| $name *" if distrobox list --no-color | string match -q "*| $name *"
distrobox enter $name distrobox enter $name
+5
View File
@@ -0,0 +1,5 @@
[user]
name = fe5hua
email = git@fe5hua.de
[init]
defaultBranch = main
+25 -4
View File
@@ -11,8 +11,9 @@ export DEV_USER="$(basename "$DEV_HOME")"
# Software directories # Software directories
# ----------------------------------------------------------------------------- # -----------------------------------------------------------------------------
mkdir -p /opt/rustup /opt/cargo /opt/aseprite mkdir -p /opt/rustup /opt/cargo /opt/aseprite /opt/dx /opt/npm-global
chown "$DEV_USER:$DEV_USER" /opt/rustup /opt/cargo /opt/aseprite chown -R "$DEV_USER:$DEV_USER" /opt/rustup /opt/cargo /opt/aseprite /opt/dx /opt/npm-global
# TODO basically all commamd from here on need to run as $DEV_USER, but scrpt runs as root
# ----------------------------------------------------------------------------- # -----------------------------------------------------------------------------
# Fish configuration # Fish configuration
@@ -50,7 +51,7 @@ fi
# Rust toolchain # Rust toolchain
echo "Installing stable Rust toolchain..." echo "Installing stable Rust toolchain..."
/opt/cargo/bin/rustup default stable /opt/cargo/bin/rustup default nightly
# Fish completions # Fish completions
echo "Installing rustup Fish completion..." echo "Installing rustup Fish completion..."
@@ -59,6 +60,23 @@ echo "Installing rustup Fish completion..."
| tee /etc/fish/completions/rustup.fish >/dev/null | tee /etc/fish/completions/rustup.fish >/dev/null
# Dioxus CLI
export DX_INSTALL=/opt/dx
if [[ ! -x /opt/cargo/bin/dx ]]; then
echo "Installing dioxus cli..."
# TODO needs to run as user, not root
curl -sSL https://dioxus.dev/install.sh | bash
else
echo "dioxus cli is already installed."
fi
# -----------------------------------------------------------------------------
# NodeJS and NPM
# -----------------------------------------------------------------------------
npm config set prefix '/opt/npm-global'
# ----------------------------------------------------------------------------- # -----------------------------------------------------------------------------
# Aseprite # Aseprite
# ----------------------------------------------------------------------------- # -----------------------------------------------------------------------------
@@ -155,7 +173,10 @@ for binary in \
rust-gdb \ rust-gdb \
rust-gdbgui \ rust-gdbgui \
rust-lldb \ rust-lldb \
rustup rustup \
dx \
npm \
node
do do
export_bin "$binary" export_bin "$binary"
done done