1
0
mirror of https://github.com/robbyrussell/oh-my-zsh.git synced 2025-12-06 07:20:40 +01:00

Compare commits

9 Commits

Author SHA1 Message Date
dependabot[bot]
69773683f9 chore(deps): bump urllib3 in /.github/workflows/dependencies
Bumps [urllib3](https://github.com/urllib3/urllib3) from 2.5.0 to 2.6.0.
- [Release notes](https://github.com/urllib3/urllib3/releases)
- [Changelog](https://github.com/urllib3/urllib3/blob/main/CHANGES.rst)
- [Commits](https://github.com/urllib3/urllib3/compare/2.5.0...2.6.0)

---
updated-dependencies:
- dependency-name: urllib3
  dependency-version: 2.6.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-06 04:47:29 +00:00
Cyril Plisko
a98a9f7122 feat(jj): add jj aliases for common workflows (#13179)
- jj bookmark
    Aliases for bookmark subcommands
- jj git push
    Aliases for popular push flags
- jj new "trunk()"
- jj rebase -d "trunk()"
- jj status
2025-12-05 12:00:56 +01:00
benzlokzik
5f7f419759 feat(uv): add alias for pinning Python version (#12914) 2025-12-05 08:51:45 +01:00
Marc Cornellà
e9fc134236 ci(dependencies): update job permissions, change commits to chore (#13457) 2025-12-01 11:22:14 +01:00
Marc Cornellà
977c4f93a6 refactor(rbfu)!: remove deprecated rbfu plugin
BREAKING CHANGE: `rbfu`, the tool to manage Ruby versions, has long
been deprecated (2013-02-05). The plugin has been removed. If you
were still using it, consider using alternative Ruby version
managers: https://www.jetbrains.com/help/ruby/ruby-version-managers.html
2025-12-01 11:21:13 +01:00
Marc Cornellà
ee30bc535a refactor(fig)!: remove archived fig plugin
BREAKING CHANGE: the fig plugin has been removed. `fig` was sunset
on September 1, 2024. Having this plugin no longer makes sense.
See https://fig.io/ for more information.
2025-12-01 11:21:13 +01:00
Carlo Sala
ca5c467db1 fix(dependencies): only open PR if there are relevant changes (#13454)
Fixes cases like #13453
2025-12-01 09:59:09 +01:00
dependabot[bot]
a449c0247d chore(deps): bump actions/setup-python from 6.0.0 to 6.1.0 (#13455)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 6.0.0 to 6.1.0.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](e797f83bcb...83679a892e)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-version: 6.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-30 16:29:07 +01:00
dependabot[bot]
343c5a83cb chore(deps): bump github/codeql-action from 4.31.4 to 4.31.5 (#13456)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.4 to 4.31.5.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](e12f017898...fdbfb4d275)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-30 16:28:47 +01:00
12 changed files with 80 additions and 127 deletions

View File

@@ -4,14 +4,13 @@ on:
schedule:
- cron: "0 6 * * 0"
permissions:
contents: write
jobs:
check:
name: Check for updates
runs-on: ubuntu-latest
if: github.repository == 'ohmyzsh/ohmyzsh'
permissions:
contents: write # this is needed to push commits and branches
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
@@ -29,7 +28,7 @@ jobs:
app-id: ${{ secrets.OHMYZSH_APP_ID }}
private-key: ${{ secrets.OHMYZSH_APP_PRIVATE_KEY }}
- name: Setup Python
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6.0.0
uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
with:
python-version: "3.12"
cache: "pip"

View File

@@ -4,4 +4,4 @@ idna==3.11
PyYAML==6.0.3
requests==2.32.5
semver==3.0.4
urllib3==2.5.0
urllib3==2.6.0

View File

@@ -219,32 +219,33 @@ class Dependency:
# Create new branch
branch = Git.checkout_or_create_branch(branch_name)
# Update dependencies.yml file
self.__update_yaml(
f"tag:{new_version}" if is_tag else status["version"]
)
# Update dependency files
self.__apply_upstream_changes()
# Add all changes and commit
has_new_commit = Git.add_and_commit(self.name, new_version)
if has_new_commit:
# Push changes to remote
Git.push(branch)
# Create GitHub PR
GitHub.create_pr(
branch,
f"feat({self.name}): update to version {new_version}",
f"""## Description
Update for **{self.desc}**: update to version [{new_version}]({status['head_url']}).
Check out the [list of changes]({status['compare_url']}).
""",
if not Git.repo_is_clean():
# Update dependencies.yml file
self.__update_yaml(
f"tag:{new_version}" if is_tag else status["version"]
)
# Add all changes and commit
has_new_commit = Git.add_and_commit(self.name, new_version)
if has_new_commit:
# Push changes to remote
Git.push(branch)
# Create GitHub PR
GitHub.create_pr(
branch,
f"chore({self.name}): update to version {new_version}",
f"""## Description
Update for **{self.desc}**: update to version [{new_version}]({status["head_url"]}).
Check out the [list of changes]({status["compare_url"]}).
""",
)
# Clean up repository
Git.clean_repo()
except (CommandRunner.Exception, shutil.Error) as e:
@@ -275,8 +276,8 @@ Check out the [list of changes]({status['compare_url']}).
There is a new version of `{self.name}` {self.kind} available.
New version: [{new_version}]({status['head_url']})
Check out the [list of changes]({status['compare_url']}).
New version: [{new_version}]({status["head_url"]})
Check out the [list of changes]({status["compare_url"]}).
"""
print("Creating GitHub issue", file=sys.stderr)
@@ -377,21 +378,28 @@ class Git:
)
return branch_name
@staticmethod
def repo_is_clean() -> bool:
"""
Returns `True` if the repo is clean.
Returns `False` if the repo is dirty.
"""
try:
CommandRunner.run_or_fail(
["git", "diff", "--exit-code"], stage="CheckRepoClean"
)
return True
except CommandRunner.Exception:
return False
@staticmethod
def add_and_commit(scope: str, version: str) -> bool:
"""
Returns `True` if there were changes and were indeed commited.
Returns `False` if the repo was clean and no changes were commited.
"""
# check if repo is clean (clean => no error, no commit)
try:
CommandRunner.run_or_fail(
["git", "diff", "--exit-code"], stage="CheckRepoClean"
)
if Git.repo_is_clean():
return False
except CommandRunner.Exception:
# if it's other kind of error just throw!
pass
user_name = os.environ.get("GIT_APP_NAME")
user_email = os.environ.get("GIT_APP_EMAIL")
@@ -415,7 +423,7 @@ class Git:
f"user.email={user_email}",
"commit",
"-m",
f"feat({scope}): update to {version}",
f"chore({scope}): update to {version}",
],
stage="CreateCommit",
env=clean_env,

View File

@@ -60,6 +60,6 @@ jobs:
retention-days: 5
- name: "Upload to code-scanning"
uses: github/codeql-action/upload-sarif@e12f0178983d466f2f6028f5cc7a6d786fd97f4b # v4.31.4
uses: github/codeql-action/upload-sarif@fdbfb4d2750291e159f0156def62b853c2798ca2 # v4.31.5
with:
sarif_file: results.sarif

View File

@@ -1,9 +0,0 @@
# Fig plugin
This plugin sets up completion for [Fig](https://fig.io/).
To use it, add `fig` to the plugins array in your zshrc file:
```zsh
plugins=(... fig)
```

View File

@@ -1,13 +0,0 @@
if ! (( $+commands[fig] )); then
return
fi
# If the completion file doesn't exist yet, we need to autoload it and
# bind it to `fig`. Otherwise, compinit will have already done that
if [[ ! -f "$ZSH_CACHE_DIR/completions/_fig" ]]; then
autoload -Uz _fig
typeset -g -A _comps
_comps[fig]=_fig
fi
fig completion zsh >| "$ZSH_CACHE_DIR/completions/_fig" &|

View File

@@ -12,6 +12,16 @@ plugins=(... jj)
| Alias | Command |
| ------ | ----------------------------- |
| jjb | `jj bookmark` |
| jjbc | `jj bookmark create` |
| jjbd | `jj bookmark delete` |
| jjbf | `jj bookmark forget` |
| jjbl | `jj bookmark list` |
| jjbm | `jj bookmark move` |
| jjbr | `jj bookmark rename` |
| jjbs | `jj bookmark set` |
| jjbt | `jj bookmark track` |
| jjbu | `jj bookmark untrack` |
| jjc | `jj commit` |
| jjcmsg | `jj commit --message` |
| jjd | `jj diff` |
@@ -22,14 +32,20 @@ plugins=(... jj)
| jjgf | `jj git fetch` |
| jjgfa | `jj git fetch --all-remotes` |
| jjgp | `jj git push` |
| jjgpa | `jj git push --all` |
| jjgpd | `jj git push --deleted` |
| jjgpt | `jj git push --tracked` |
| jjl | `jj log` |
| jjla | `jj log -r "all()"` |
| jjn | `jj new` |
| jjnt | `jj new "trunk()"` |
| jjrb | `jj rebase` |
| jjrbm | `jj rebase -d "trunk()"` |
| jjrs | `jj restore` |
| jjrt | `cd "$(jj root \|\| echo .)"` |
| jjsp | `jj split` |
| jjsq | `jj squash` |
| jjst | `jj status` |
## Prompt usage
@@ -88,3 +104,4 @@ that.
## Contributors
- [nasso](https://github.com/nasso) - Plugin Author
- [imp](https://github.com/imp) - Occasional Alias Contributor

View File

@@ -34,6 +34,16 @@ function jj_prompt_template() {
}
# Aliases (sorted alphabetically)
alias jjb='jj bookmark'
alias jjbc='jj bookmark create'
alias jjbd='jj bookmark delete'
alias jjbf='jj bookmark forget'
alias jjbl='jj bookmark list'
alias jjbm='jj bookmark move'
alias jjbr='jj bookmark rename'
alias jjbs='jj bookmark set'
alias jjbt='jj bookmark track'
alias jjbu='jj bookmark untrack'
alias jjc='jj commit'
alias jjcmsg='jj commit --message'
alias jjd='jj diff'
@@ -44,11 +54,17 @@ alias jjgcl='jj git clone'
alias jjgf='jj git fetch'
alias jjgfa='jj git fetch --all-remotes'
alias jjgp='jj git push'
alias jjgpa='jj git push --all'
alias jjgpd='jj git push --deleted'
alias jjgpt='jj git push --tracked'
alias jjl='jj log'
alias jjla='jj log -r "all()"'
alias jjn='jj new'
alias jjnt='jj new "trunk()"'
alias jjrb='jj rebase'
alias jjrbm='jj rebase -d "trunk()"'
alias jjrs='jj restore'
alias jjrt='cd "$(jj root || echo .)"'
alias jjsp='jj split'
alias jjsq='jj squash'
alias jjst='jj status'

View File

@@ -1,18 +0,0 @@
# rbfu plugin
This plugin starts [rbfu](https://github.com/hmans/rbfu), a minimal Ruby version
manager, and adds some useful functions.
To use it, add `rbfu` to the plugins array in your zshrc file:
```zsh
plugins=(... rbfu)
```
**Note: `rbfu` is deprecated and should no longer be used.**
## Functions
- `rbfu-rubies`: lists all installed rubies available to rbfu.
- `rvm_prompt_info`: shows the Ruby version being used with rbfu.

View File

@@ -1,49 +0,0 @@
# Enables rbfu with --auto option, if available.
#
# Also provides a command to list all installed/available
# rubies. To ensure compatibility with themes, creates the
# rvm_prompt_info function to return the $RBFU_RUBY_VERSION
# version.
command -v rbfu &>/dev/null || return
eval "$(rbfu --init --auto)"
# Internal: Print ruby version details, if it's currently active, etc.
function _rbfu_rubies_print() {
# 1: path to ruby file
# 2: active ruby
local rb rb_out
rb="${$1:t}"
rb_out="$rb"
# If the ruby is a symlink, add @ to the name.
if [[ -h "$1" ]]; then
rb_out="${rb_out}${fg[green]}@${reset_color}"
fi
# If the ruby is active, add * to the name and show it in red.
if [[ "$rb" = "$2" ]]; then
rb_out="${fg[red]}${rb_out} ${fg[red]}*${reset_color}"
fi
echo $rb_out
}
# Public: Provide a list with all available rubies, this basically depends
# on ~/.rfbu/rubies. Highlights the currently active ruby version and aliases.
function rbfu-rubies() {
local rbfu_dir active_rb
rbfu_dir="${RBFU_RUBIES:-${HOME}/.rbfu/rubies}"
active_rb="${RBFU_RUBY_VERSION:-system}"
_rbfu_rubies_print "${rbfu_dir}/system" "$active_rb"
for rb in ${rbfu_dir}/*(N); do
_rbfu_rubies_print "$rb" "$active_rb"
done
}
# Public: Create rvm_prompt_info command for themes compatibility, unless
# it has already been defined.
(( ${+functions[rvm_prompt_info]} )) || \
function rvm_prompt_info() { echo "${${RBFU_RUBY_VERSION:=system}:gs/%/%%}" }

View File

@@ -19,6 +19,7 @@ plugins=(... uv)
| uvlu | `uv lock --upgrade` | Lock the dependencies to the newest compatible versions |
| uvp | `uv pip` | Manage pip packages |
| uvpy | `uv python` | Manage Python installs |
| uvpp | `uv python pin` | Pin the current project to use a specific Python version |
| uvr | `uv run` | Run commands within the project's environment |
| uvrm | `uv remove` | Remove packages from the project |
| uvs | `uv sync` | Sync the environment with the lock file |

View File

@@ -12,6 +12,7 @@ alias uvlr='uv lock --refresh'
alias uvlu='uv lock --upgrade'
alias uvp='uv pip'
alias uvpy='uv python'
alias uvpp='uv python pin'
alias uvr='uv run'
alias uvrm='uv remove'
alias uvs='uv sync'