mirror of
https://github.com/denisidoro/navi
synced 2024-11-22 03:23:05 +00:00
a36c26f922
Fixes #546 and #553
38 lines
854 B
Bash
Executable file
38 lines
854 B
Bash
Executable file
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
export NAVI_HOME="$(cd "$(dirname "$0")/.." && pwd)"
|
|
source "${NAVI_HOME}/scripts/install"
|
|
|
|
_commit() {
|
|
if [ -n "${DOTFILES:-}" ]; then
|
|
git add --all || true
|
|
dot git commit am || true
|
|
fi
|
|
}
|
|
|
|
cd "$NAVI_HOME"
|
|
|
|
_commit
|
|
log::note "cargo clippy fix..."
|
|
cargo +nightly clippy --fix -Z unstable-options || true
|
|
|
|
_commit
|
|
log::note "cargo fix..."
|
|
cargo fix || true
|
|
|
|
_commit
|
|
log::note "cargo fmt..."
|
|
cargo fmt || true
|
|
|
|
_commit
|
|
log::note "clippy..."
|
|
cargo clippy || true
|
|
|
|
_commit
|
|
log::note "dot code beautify..."
|
|
find scripts -type f | xargs -I% dot code beautify % || true
|
|
dot code beautify "${NAVI_HOME}/shell/navi.plugin.bash" || true
|
|
dot code beautify "${NAVI_HOME}/shell/navi.plugin.zsh" || true
|
|
dot code beautify "${NAVI_HOME}/tests/core.bash" || true
|
|
dot code beautify "${NAVI_HOME}/tests/run" || true
|