Просмотр исходного кода

v1.0.0 (fixes #520)

pull/673/head v1.0.0
Yamashita, Yuu 10 лет назад
Родитель
Сommit
7fadd939ad
3 измененных файлов: 7 добавлений и 7 удалений
  1. +1
    -1
      CHANGELOG.md
  2. +1
    -1
      libexec/pyenv---version
  3. +5
    -5
      test/--version.bats

+ 1
- 1
CHANGELOG.md Просмотреть файл

@ -1,6 +1,6 @@
## Version History ## Version History
## Unreleased
## 1.0.0
* pyenv: Import latest changes from rbenv as of Aug 15, 2016 (#669) * pyenv: Import latest changes from rbenv as of Aug 15, 2016 (#669)
* pyenv: Add workaround for system python at `/bin/python` (#628) * pyenv: Add workaround for system python at `/bin/python` (#628)

+ 1
- 1
libexec/pyenv---version Просмотреть файл

@ -12,7 +12,7 @@
set -e set -e
[ -n "$PYENV_DEBUG" ] && set -x [ -n "$PYENV_DEBUG" ] && set -x
version="20160726"
version="1.0.0"
git_revision="" git_revision=""
if cd "${BASH_SOURCE%/*}" 2>/dev/null && git remote -v 2>/dev/null | grep -q pyenv; then if cd "${BASH_SOURCE%/*}" 2>/dev/null && git remote -v 2>/dev/null | grep -q pyenv; then

+ 5
- 5
test/--version.bats Просмотреть файл

@ -19,7 +19,7 @@ git_commit() {
assert [ ! -e "$PYENV_ROOT" ] assert [ ! -e "$PYENV_ROOT" ]
run pyenv---version run pyenv---version
assert_success assert_success
[[ $output == "pyenv 20"* ]]
[[ $output == "pyenv "?.?.? ]]
} }
@test "doesn't read version from non-pyenv repo" { @test "doesn't read version from non-pyenv repo" {
@ -30,19 +30,19 @@ git_commit() {
run pyenv---version run pyenv---version
assert_success assert_success
[[ $output == "pyenv 20"* ]]
[[ $output == "pyenv "?.?.? ]]
} }
@test "reads version from git repo" { @test "reads version from git repo" {
git init git init
git remote add origin https://github.com/yyuu/pyenv.git git remote add origin https://github.com/yyuu/pyenv.git
git_commit git_commit
git tag v20380119
git tag v0.4.1
git_commit git_commit
git_commit git_commit
run pyenv---version run pyenv---version
assert_success "pyenv 20380119-2-g$(git rev-parse --short HEAD)"
assert_success "pyenv 0.4.1-2-g$(git rev-parse --short HEAD)"
} }
@test "prints default version if no tags in git repo" { @test "prints default version if no tags in git repo" {
@ -51,5 +51,5 @@ git_commit() {
git_commit git_commit
run pyenv---version run pyenv---version
[[ $output == "pyenv 20"* ]]
[[ $output == "pyenv "?.?.? ]]
} }

Загрузка…
Отмена
Сохранить