Skip to content

Commit

Permalink
Fix plugin register
Browse files Browse the repository at this point in the history
  • Loading branch information
hustcer committed Jun 26, 2024
1 parent 8eea20c commit 1466f81
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion nu/common.nu
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export def compare-ver [
# Ignore '-beta' or '-rc' suffix
let v1 = ($source | split row '.' | each {|it| ($it | parse -r '(?P<v>\d+)' | get v | get 0 )})
let v2 = ($dest | split row '.' | each {|it| ($it | parse -r '(?P<v>\d+)' | get v | get 0 )})
for $v in $v1 -n {
for $v in ($v1 | enumerate) {
let c1 = ($v1 | get -i $v.index | default 0 | into int)
let c2 = ($v2 | get -i $v.index | default 0 | into int)
if $c1 > $c2 {
Expand Down
2 changes: 1 addition & 1 deletion nu/register-plugins.nu
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def main [
] {

let name = if $version =~ 'nightly' { 'nightly' } else { 'nushell' }
let useRegister = if $version =~ 'nightly' or $version == '*' or (is-lower-ver 0.93.0 $version) { false } else { true }
let useRegister = if $version =~ 'nightly' or $version == '*' or (is-lower-ver 0.92.0 $version) { false } else { true }
let config_path = ($nu.env-path | path dirname)
let config_prefix = $'https://github.com/nushell/($name)/blob/($version)/crates/nu-utils/src'
aria2c $'($config_prefix)/sample_config/default_env.nu' -o env.nu -d $config_path
Expand Down

0 comments on commit 1466f81

Please sign in to comment.