From a35cd568ce69a610a7806ff690e673d2447b3dc6 Mon Sep 17 00:00:00 2001 From: david Date: Sun, 16 Nov 2025 01:04:07 -0600 Subject: [PATCH] Replace mise-activate with simple wrapper scripts and ENV vars The prompting for this change is to use mise within ksh/oksh without having to rely on zsh (such as `zsh -c "mise activate zsh"` or otherwise). I kind of like the simplicity of this, and then I can still easily change versions as needed in a given project by sourcing a file which exports different vars for target language versions, or I can just do manual export commands from the shell. --- installs_and_builds/programs.csv | 1 + src_files/.config/zsh/.zshrc | 1 - src_files/.local/bin/go | 3 +++ src_files/.local/bin/python | 3 +++ src_files/.local/bin/ruby | 3 +++ src_files/shell/profile | 5 +++++ 6 files changed, 15 insertions(+), 1 deletion(-) create mode 100755 src_files/.local/bin/go create mode 100755 src_files/.local/bin/python create mode 100755 src_files/.local/bin/ruby diff --git a/installs_and_builds/programs.csv b/installs_and_builds/programs.csv index 00e2f71..099d027 100644 --- a/installs_and_builds/programs.csv +++ b/installs_and_builds/programs.csv @@ -6,6 +6,7 @@ coreutils,package_manager,linux: name='',,, findutils,package_manager,linux: name='',,, make,package_manager,,,, cmake,package_manager,,,, +mise,build_custom,,,,TODO implement the build_custom script for this mpv,package_manager,,,, kitty,package_manager,macos: name='--cask kitty',,, zsh,package_manager,,,, diff --git a/src_files/.config/zsh/.zshrc b/src_files/.config/zsh/.zshrc index 67d6fd9..affff8e 100644 --- a/src_files/.config/zsh/.zshrc +++ b/src_files/.config/zsh/.zshrc @@ -62,6 +62,5 @@ alias weather='curl "wttr.in/dfw?2&F"' alias shrug='echo "¯\\_(ツ)_/¯"' # programming and language setup -[[ -n $(command -v mise) ]] && eval "$(mise activate zsh)" export DEVKITARM=/opt/devkitpro/devkitARM diff --git a/src_files/.local/bin/go b/src_files/.local/bin/go new file mode 100755 index 0000000..9cb704b --- /dev/null +++ b/src_files/.local/bin/go @@ -0,0 +1,3 @@ +#!/bin/sh + +mise exec go@$MISE_GO_VERSION -- go "$@" diff --git a/src_files/.local/bin/python b/src_files/.local/bin/python new file mode 100755 index 0000000..381ea3c --- /dev/null +++ b/src_files/.local/bin/python @@ -0,0 +1,3 @@ +#!/bin/sh + +mise exec python@$MISE_PYTHON_VERSION -- python "$@" diff --git a/src_files/.local/bin/ruby b/src_files/.local/bin/ruby new file mode 100755 index 0000000..af2028d --- /dev/null +++ b/src_files/.local/bin/ruby @@ -0,0 +1,3 @@ +#!/bin/sh + +mise exec ruby@$MISE_RUBY_VERSION -- ruby "$@" diff --git a/src_files/shell/profile b/src_files/shell/profile index 81a5c96..3d796c4 100644 --- a/src_files/shell/profile +++ b/src_files/shell/profile @@ -41,6 +41,11 @@ export GIT_EDITOR="$EDITOR" # obsidian export OBSIDIAN_WORKSPACES_TO_CONFIGURE="$DIR_NOTES," # ,-delimitted list of dirs +# language and tool vars +export MISE_GO_VERSION="1.25.1" +export MISE_PYTHON_VERSION="3.13.7" +export MISE_RUBY_VERSION="3.4.7" + # reaper export DIR_REAPER_PORTABLE_SHARED="$DIR_USER_OPT/reaper-portable/shared" export DIR_REAPER_PORTABLE_LINUX="$DIR_USER_OPT/reaper-portable/linux"