yannjor / krabby Goto Github PK
View Code? Open in Web Editor NEWPrint pokemon sprites in your terminal
License: GNU General Public License v3.0
Print pokemon sprites in your terminal
License: GNU General Public License v3.0
nix build .#krabby
warning: found empty hash, assuming 'sha256-AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA='
warning: error: unable to download 'https://mirrors.tuna.tsinghua.edu.cn/nix-channels/store/61zxvc6ldb8j6292dn5b4bz31n2qlq8d.narinfo': SSL connect error (35); retrying in 308 ms
[1/0/2 built, 0.0 MiB DL] building krabby-0.1.6-vendor.tar.gz (unpackPhase): unpacking source archive /nix/store/gc1yvn29j9ywf9b77jb4
error: builder for '/nix/store/6lks3ql04s2ya00sffn03h0qga6xy19h-krabby-0.1.6-vendor.tar.gz.drv' failed with exit code 1;
last 10 log lines:
> patching sources
> configuring
> no configure script, doing nothing
> building
>
> ERROR: The Cargo.lock file doesn't exist
>
> Cargo.lock is needed to make sure that cargoHash/cargoSha256 doesn't change
> when the registry is updated.
>
For full logs, run 'nix log /nix/store/6lks3ql04s2ya00sffn03h0qga6xy19h-krabby-0.1.6-vendor.tar.gz.drv'.
error: 1 dependencies of derivation '/nix/store/rbnc1dmqxbqkp26rkb81nflfh06cmz70-krabby-0.1.6.drv' failed to build
Is there an option to get this output to neofetch? (using image_source command output)
name
subcommand already has a --shiny
flag, which makes it possible to display a shiny version of a specified Pokemon.
random
subcommand could also have that flag so that we could get a random shiny Pokemon.
I know it's possible to achieve this by setting the shiny probability to 1
in the configuration file, but a flag would be nice too. I can imagine some use cases with that.
Hey @yannjor I finally got around to testing your codebase and added a column to the comparison table.
Let me know if you have any qualms or suggestions.
One thing to note, is that the bash script pokeget
(cached) is actually faster than krabby
(cached). I was wondering if you have any thoughts and if u can also reproduce those results.
Comparing with the old version of the bash script, I get that krabby is 1.3x slower instead of 7x faster.
It would be great to be able to specify a number of spaced for padding (e.g., on the left). This would allow having an output like (sorry, the ANSI characters don't render well here on GitHub):
$ krabby random --padding-left 8
Clefairy
▄▀▄ ▄▄▄
▀▀▀▀▀▀▀▀▄▄▄▄▄▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
▀▀▀▀▀▀▀▀▀▀
▀▀
instead of
$ krabby random
Clefairy
▄▀▄ ▄▄▄
▀▀▀▀▀▀▀▀▄▄▄▄▄▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
▀▀▀▀▀▀▀▀▀▀
▀▀
It would simply mean prefixing every output line with X amount of spaces.
Hi, thanks for your work.
I have an idea, how can we hide the pokemon name? I don't see any configuration to do that. It would be nice if we had an option for that.
Thanks a lot.
Add shell completions for the name command. This should be possible with clap. See: https://dev.to/kbknapp/cli-shell-completions-in-rust-37g1
I was charmed by your project, so I wrote a PKGBUILD that tracks the main branch
pkgbase='krabby-git'
pkgname='krabby-git'
pkgver=0.1.6.r0.g2669909
pkgrel=1
pkgdesc='Print pokemon sprites in your terminal (development version)'
arch=('x86_64')
url='https://github.com/yannjor/krabby'
license=('GPL-3.0')
makedepends=('rust')
conflicts=('krabby')
source=("${pkgname}::git+https://github.com/yannjor/krabby#branch=main")
md5sums=('SKIP')
pkgver() {
git -C "${pkgname}" describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}
build() {
cd "${pkgname}"
cargo build --release
}
package() {
install -Dm755 "${pkgname}/target/release/krabby" -t "${pkgdir}/usr/bin"
install -Dm644 "${pkgname}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
I noticed that the krabby-git AUR package is orphaned, perhaps you can adopt it & update it using this script (I would do it myself, but I figured you might prefer to do it yourself considering it's your project). A krabby package might be nice as well; I could write a PKGBUILD for that as well if you want.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.