mise
mise copied to clipboard
mise not skipping tasks
Describe the bug
mise
doesn't appear to be respecting the sources
and outputs
to skip running a task.
To Reproduce
I have this in my mise.toml
[tasks.bundle_id]
sources = ['*.xcodeproj']
outputs = ['.bundle_id']
run = """
#!/usr/bin/env bash
xcodebuild -showBuildSettings | grep PRODUCT_BUNDLE_IDENTIFIER | awk -F ' = ' '{print $2}' > .bundle_id
"""
[tasks.reload]
alias = "default"
depends = ["bundle_id"]
# ...
Expected behavior
The docs seem to suggest that bundle_id
should be skipped if .bundle_id
is newer than any .xcodeproj
file, but it's running every time I run the reload
task. Running mise run bundle_id
also re-runs the command (though maybe that last bit is intentional?). It's also worth noting that .xcodeproj
files are really directories.
mise doctor
output
version: 2024.4.0 macos-arm64 (2024-04-02)
activated: yes
shims_on_path: no
build_info:
Target: aarch64-apple-darwin
Features: DEFAULT, NATIVE_TLS
Built: Tue, 2 Apr 2024 01:55:39 +0000
Rust Version: rustc 1.77.1 (7cf61ebde 2024-03-27) (Homebrew)
Profile: release
shell:
/opt/homebrew/bin/fish
fish, version 3.7.0
dirs:
data: ~/.local/share/mise
config: ~/.config/mise
cache: ~/Library/Caches/mise
state: ~/.local/state/mise
shims: ~/.local/share/mise/shims
config_files:
~/.tool-versions
~/.config/mise/config.toml
~/scratch/xcode/ariadne/.mise.toml
plugins:
bun (core)
deno (core)
erlang (core)
go (core)
java (core)
node (core)
python (core)
ruby (core)
usage https://github.com/jdx/mise-usage.git#fe3888a
watchexec https://github.com/nyrst/asdf-watchexec.git#b667a08
toolset:
[email protected]
[email protected]
[email protected] (missing)
[email protected] (missing)
env_vars:
MISE_SHELL=fish
settings:
activate_aggressive = false
all_compile = false
always_keep_download = false
always_keep_install = false
asdf_compat = false
cargo_binstall = true
color = true
disable_default_shorthands = false
disable_tools = []
experimental = true
go_default_packages_file = "~/.default-go-packages"
go_download_mirror = "https://dl.google.com/go"
go_repo = "https://github.com/golang/go"
go_set_gopath = false
go_set_goroot = true
go_skip_checksum = false
jobs = 4
legacy_version_file = true
legacy_version_file_disable_tools = []
node_compile = false
not_found_auto_install = true
paranoid = false
plugin_autoupdate_last_check_duration = "7d"
python_compile = false
python_default_packages_file = "/Users/hofstee/.default-python-packages"
python_pyenv_repo = "https://github.com/pyenv/pyenv.git"
raw = false
trusted_config_paths = []
quiet = false
verbose = false
yes = false
ci = false
debug = false
trace = false
log_level = "info"
python_venv_auto_create = false
[status]
missing_tools = "if_other_versions_installed"
show_env = false
show_tools = false
No problems found
Additional context
I was originally trying to figure out how to get an [env]
variable from the mise.toml
into the task run
command, but since the command takes a couple seconds to run and there's no caching for environment variables (as mentioned in https://github.com/jdx/mise/issues/1261) I tried to make it output to a file instead so I could skip the task when the dependencies weren't modified.