-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Fletcher Nichol <[email protected]>
- Loading branch information
Showing
6 changed files
with
30 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "names" | ||
version = "0.10.0" | ||
version = "0.11.0" | ||
authors = ["Fletcher Nichol <[email protected]>"] | ||
license = "MIT" | ||
readme = "README.md" | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "names-cli" | ||
version = "0.10.0" | ||
version = "0.11.0" | ||
authors = ["Fletcher Nichol <[email protected]>"] | ||
license = "MIT" | ||
repository = "https://github.com/fnichol/names.git" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -44,22 +44,22 @@ If you're ever confused, at least there's help: | |
|
||
```sh | ||
> names --help | ||
names 0.10.0 | ||
names 0.11.0 | ||
|
||
Author: Fletcher Nichol <[email protected]> | ||
|
||
A random name generator with results like `delirious-pail'. | ||
USAGE: | ||
names [FLAGS] [ARGS] | ||
names [FLAGS] [ARGS] | ||
FLAGS: | ||
-h, --help Prints help information | ||
-n, --number Adds a random number to the name(s) | ||
-V, --version Prints version information | ||
ARGS: | ||
amount Number of names to generate (default: 1) | ||
[amount] Number of names to generate (default: 1) | ||
``` | ||
## Installation | ||
|
@@ -94,23 +94,23 @@ If you want (or need) to build the CLI from source, the following should not tak | |
|
||
#### A static binary on Linux? | ||
|
||
This project was used by its author to experiment with producing static binaries on Linux from a Rust project that has no external dependencies. This was done using a special build of Rust that supports the [musl](http://www.musl-libc.org/) libc project, available via the [fnichol/rust:1.4.0-musl](https://hub.docker.com/r/fnichol/rust/) Docker image. Here's an example building the CLI to a static ELF binary on Linux: | ||
This project was used by its author to experiment with producing static binaries on Linux from a Rust project that has no external dependencies. This was done using a special build of Rust that supports the [musl](http://www.musl-libc.org/) libc project, available via the [fnichol/rust:1.8.0-musl](https://hub.docker.com/r/fnichol/rust/) Docker image. Here's an example building the CLI to a static ELF binary on Linux: | ||
|
||
```sh | ||
> git clone https://github.com/fnichol/names.git | ||
> cd names | ||
> docker run --rm -ti -v `pwd`:/src -w /src/cli fnichol/rust:1.4.0-musl \ | ||
> docker run --rm -ti -v `pwd`:/src -w /src/cli fnichol/rust:1.8.0-musl \ | ||
cargo build --release --target=x86_64-unknown-linux-musl | ||
|
||
> docker run --rm -ti -v `pwd`:/src fnichol/rust:1.4.0-musl \ | ||
> docker run --rm -ti -v `pwd`:/src fnichol/rust:1.8.0-musl \ | ||
du -h ./cli/target/x86_64-unknown-linux-musl/release/names | ||
1.5M ./cli/target/x86_64-unknown-linux-musl/release/names | ||
|
||
> docker run --rm -ti -v `pwd`:/src fnichol/rust:1.4.0-musl \ | ||
> docker run --rm -ti -v `pwd`:/src fnichol/rust:1.8.0-musl \ | ||
ldd ./cli/target/x86_64-unknown-linux-musl/release/names | ||
not a dynamic executable | ||
|
||
> docker run --rm -ti -v `pwd`:/src fnichol/rust:1.4.0-musl \ | ||
> docker run --rm -ti -v `pwd`:/src fnichol/rust:1.8.0-musl \ | ||
file ./cli/target/x86_64-unknown-linux-musl/release/names | ||
./cli/target/x86_64-unknown-linux-musl/release/names: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), statically linked, BuildID[sha1]=6ad327ca3a5b21c42fa158832d89f6e9b0fc8e73, not stripped | ||
``` | ||
|
@@ -121,7 +121,7 @@ A variant of this approach is used in the [build_linux.sh](https://github.com/fn | |
```sh | ||
> git clone https://github.com/fnichol/names.git | ||
> cd names | ||
> ./cli/scripts/build_linux.sh 0.10.0 | ||
> ./cli/scripts/build_linux.sh 0.11.0 | ||
|
||
> du -h ./cli/target/x86_64-unknown-linux-musl/release/names | ||
996K ./cli/target/x86_64-unknown-linux-musl/release/names | ||
|
@@ -130,8 +130,8 @@ A variant of this approach is used in the [build_linux.sh](https://github.com/fn | |
./cli/target/x86_64-unknown-linux-musl/release/names: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), statically linked, stripped | ||
|
||
> du -csh ./cli/target/names*.zip* | ||
396K cli/target/names_0.10.0_linux_x86_64.zip | ||
4.0K cli/target/names_0.10.0_linux_x86_64.zip.sha256 | ||
396K cli/target/names_0.11.0_linux_x86_64.zip | ||
4.0K cli/target/names_0.11.0_linux_x86_64.zip.sha256 | ||
400K total | ||
``` | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters