HEX
Server: Apache
System: Linux s198.coreserver.jp 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC 2025 x86_64
User: nagasaki (10062)
PHP: 7.1.33
Disabled: NONE
Upload Files
File: //usr/local/rvm/scripts/functions/notes/warnings/warning_path_reset
#!/usr/bin/env bash

__rvm_notes_warning_path_reset()
{
  \typeset -a __files

  __files=()

  for __file in ~/.zlogin ~/.zshrc ~/.bash_profile ~/.bashrc
  do
    if [[ -f "${__file}" ]]
    then __files+=( "${__file}" )
    fi
  done

  if
    [[ ${rvm_ignore_dotfiles_flag:-0} == 0 ]] &&
    (( ${#__files[@]} )) &&
    __rvm_grep -rn '^[^#]*PATH=' "${__files[@]}" |
      __rvm_grep -vE '[[:alnum:]_]PATH=|PATH=.*PATH'
  then
    # account for __rvm_grep not showing file name for just one file checked
    if (( ${#__files[*]} == 1 ))
    then __file="Your '${__files[*]}'"
    else __file="Above files"
    fi

    rvm_warn "
  * WARNING: ${__file} contains <code>PATH=</code> <warn>with no <code>\$PATH<code> <warn>inside, this can break RVM,
    for details check https://github.com/rvm/rvm/issues/1351#issuecomment-10939525
    to avoid this warning prepend <code>\$PATH<code>
"
  fi | \command \cat - >&2
}

__rvm_notes_warning_path_reset