Skip to content

Commit

Permalink
release 1.5.1
Browse files Browse the repository at this point in the history
Signed-off-by: 迷渡 <[email protected]>
  • Loading branch information
justjavac committed Dec 22, 2021
1 parent 8e42756 commit 3496e34
Show file tree
Hide file tree
Showing 5 changed files with 70 additions and 13 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

### 1.5.1 - [2021-12-22]

- use .dvmrc (#60)

### 1.5.0 - [2021-12-22]

- add `list-remote`
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "dvm"
version = "1.5.0"
version = "1.5.1"
license = "MIT"
authors = ["迷渡 <[email protected]>"]
edition = "2021"
Expand Down
48 changes: 39 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ Easy way to manage multiple active deno versions.

## Installation

You can install it using the installers below, or download a release binary from the [releases page](https://github.com/justjavac/dvm/releases).
You can install it using the installers below, or download a release binary from
the [releases page](https://github.com/justjavac/dvm/releases).

**With Shell:**

Expand All @@ -20,7 +21,8 @@ curl -fsSL https://deno.land/x/dvm/install.sh | sh
iwr https://deno.land/x/dvm/install.ps1 -useb | iex
```

**Note**: If you use Apple M1, please run `cargo install dvm` to support aarch64, becouse the Github Actions do not support aarch64.
**Note**: If you use Apple M1, please run `cargo install dvm` to support
aarch64, becouse the Github Actions do not support aarch64.

## Usage

Expand Down Expand Up @@ -63,14 +65,35 @@ which should output dvm's version if the installation was successful.

### Initialisation

Calling `dvm` will creates an `~/.dvm/` directory if it doesn't exist,
and all installed versions of deno will put into `~/.dvm`.
Calling `dvm` will creates an `~/.dvm/` directory if it doesn't exist, and all
installed versions of deno will put into `~/.dvm`.

```
➜ ~ dvm
Creating /Users/justjavac/.dvm
```

### .dvmrc

You can create a `.dvmrc` file containing a deno version number in the project
root directory. Afterwards, `dvm use`, `dvm install` will use the version
specified in the `.dvmrc` file if no version is supplied on the command line.

For example, to make dvm default to the `1.17.0` release for the current
directory:

```bash
echo "1.17.0" > .dvmrc
```

Then when you run dvm:

```plain
$ dvm use
Found '.dvmrc' with version <1.17.0>
Now using deno 1.17.0
```

## Example

### Listing versions
Expand All @@ -84,7 +107,8 @@ List all installed versions:
0.1.2
```

The version with a asterisk(`*`) means that this version is the version currently in use.
The version with a asterisk(`*`) means that this version is the version
currently in use.

### Switching version

Expand All @@ -94,15 +118,19 @@ now use deno 1.1.0
➜ ~ dvm use 1.2.0
deno v1.2.0 is not installed. Use `dvm install 1.2.0` to install it first.
```

## Compatibility

- The Shell installer can be used on Windows with [Windows Subsystem for Linux](https://docs.microsoft.com/en-us/windows/wsl/about), [MSYS](https://www.msys2.org) or equivalent set of tools.
- The Shell installer can be used on Windows with
[Windows Subsystem for Linux](https://docs.microsoft.com/en-us/windows/wsl/about),
[MSYS](https://www.msys2.org) or equivalent set of tools.

## Known Issues

### unzip is required

The program [`unzip`](https://linux.die.net/man/1/unzip) is a requirement for the Shell installer.
The program [`unzip`](https://linux.die.net/man/1/unzip) is a requirement for
the Shell installer.

```sh
$ curl -fsSL https://deno.land/x/dvm/install.sh | sh
Expand All @@ -115,8 +143,10 @@ During the `install.sh` process, `unzip` is used to extract the zip archive.

**How can this issue be fixed?**

You can install unzip via `brew install unzip` on MacOS or `apt-get install unzip -y` on Linux(Ubuntu,Debian,Deepin).
You can install unzip via `brew install unzip` on MacOS or
`apt-get install unzip -y` on Linux(Ubuntu,Debian,Deepin).

## License

Deno Version Manager(dvm) is released under the MIT License. See the bundled [LICENSE](./LICENSE) file for details.
Deno Version Manager(dvm) is released under the MIT License. See the bundled
[LICENSE](./LICENSE) file for details.
27 changes: 25 additions & 2 deletions README_zh-cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ curl -fsSL https://deno.land/x/dvm/install.sh | sh
iwr https://deno.land/x/dvm/install.ps1 -useb | iex
```

**注意**: 如果你使用的是 Apple M1,请使用 `cargo install dvm` 手动编译,因为 Github Actions 目前还不支持 aarch64 架构。
**注意**: 如果你使用的是 Apple M1,请使用 `cargo install dvm` 手动编译,因为 Github Actions 目前还不支持
aarch64 架构。

## 使用

Expand Down Expand Up @@ -70,6 +71,25 @@ dvm -V
Creating /Users/justjavac/.dvm
```

### .dvmrc

你可以在项目根目录创建一个 `.dvmrc` 文件,然后把 Deno 的版本号写在里面。这样当你运行 `dvm use``dvm install`
命令时,如果没有在命令行上提供版本参数,那么 dvm 会自动从 `.dvmrc` 文件读取 Deno 的版本号。

举个例子,我们想把当前仓库的 Deno 版本号设置为 `1.17.0`,那么我们可以在根目录运行:

```bash
echo "1.17.0" > .dvmrc
```

然后运行 dvm:

```plain
$ dvm use
Found '.dvmrc' with version <1.17.0>
Now using deno 1.17.0
```

## 举个例子

### 查看版本
Expand All @@ -93,9 +113,12 @@ now use deno 1.1.0
➜ ~ dvm use 1.2.0
deno v1.2.0 is not installed. Use `dvm install 1.2.0` to install it first.
```

## 兼容性

- Shell 安装程序可以在带有 [Windows Subsystem for Linux](https://docs.microsoft.com/en-us/windows/wsl/about), [MSYS](https://www.msys2.org) 或等效工具集的 Windows 上使用。
- Shell 安装程序可以在带有
[Windows Subsystem for Linux](https://docs.microsoft.com/en-us/windows/wsl/about),
[MSYS](https://www.msys2.org) 或等效工具集的 Windows 上使用。

## 常见问题

Expand Down

0 comments on commit 3496e34

Please sign in to comment.