Skip to content

Commit

Permalink
examples/gotdict-convert: Prefer the version with images (#1)
Browse files Browse the repository at this point in the history
Base64 images have been fixed in 4.20.14601. See #1.
  • Loading branch information
pgaskin committed Mar 2, 2020
1 parent d05535b commit 01da35f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -169,24 +169,24 @@ steps:
commands:
- git clone https://github.com/wjdp/gotdict
- git -C gotdict checkout 6b4d6cdbb1f5d899d418783ab842f487aafa79ec
- ./gotdict-convert -o gotdict.df
- ./gotdict-convert -o gotdict.img.df --images
- ./gotdict-convert -o gotdict.df --images
- ./gotdict-convert -o gotdict.noimg.df
- ls -lah gotdict.df
- name: generate
image: golang:1.14-buster
commands:
- go run ./cmd/dictgen -Iremove -o dicthtml-gt.zip gotdict.df
- go run ./cmd/dictgen -Ibase64 -o dicthtml-gt.img.zip gotdict.img.df
- ls -lah dicthtml-gt.zip
- go run ./cmd/dictgen -Ibase64 -o dicthtml-gt.zip gotdict.df
- go run ./cmd/dictgen -Iremove -o dicthtml-gt.noimg.zip gotdict.noimg.df
- ls -lah dicthtml-gt*.zip
- name: upload
image: curlimages/curl
entrypoint: ["/bin/bash"]
commands:
- "curl --no-progress-meter -F '[email protected]' 'https://api.anonfile.com/upload' | grep -Eo '\"full\": *\"[^\"]+' | cut -d'\"' -f4"
- "curl --no-progress-meter -F '[email protected]' 'https://api.anonfile.com/upload' | grep -Eo '\"full\": *\"[^\"]+' | cut -d'\"' -f4"
- "echo; echo 'Do not use the dictionaries with images below right now; nickel is currently too buggy with images.'"
- "curl --no-progress-meter -F 'file=@gotdict.img.df' 'https://api.anonfile.com/upload' | grep -Eo '\"full\": *\"[^\"]+' | cut -d'\"' -f4"
- "curl --no-progress-meter -F 'file=@dicthtml-gt.img.zip' 'https://api.anonfile.com/upload' | grep -Eo '\"full\": *\"[^\"]+' | cut -d'\"' -f4"
- "echo; echo 'If you are using a firmware version older than 4.20.14601, use the version without images (they cause crashes with the in-book dictionary view) below.'"
- "curl --no-progress-meter -F 'file=@gotdict.noimg.df' 'https://api.anonfile.com/upload' | grep -Eo '\"full\": *\"[^\"]+' | cut -d'\"' -f4"
- "curl --no-progress-meter -F 'file=@dicthtml-gt.noimg.zip' 'https://api.anonfile.com/upload' | grep -Eo '\"full\": *\"[^\"]+' | cut -d'\"' -f4"

trigger:
event:
Expand Down
2 changes: 1 addition & 1 deletion examples/gotdict-convert/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ func main() {
pflag.CommandLine.SortFlags = false
gotdict := pflag.StringP("gotdict", "g", "."+string(os.PathSeparator)+"gotdict", "The path to the local copy of github.com/wjdp/gotdict.")
output := pflag.StringP("output", "o", "."+string(os.PathSeparator)+"gotdict.df", "The output filename (will be overwritten if it exists) (- is stdout)")
images := pflag.BoolP("images", "I", false, "Include images in dictfile")
images := pflag.BoolP("images", "I", false, "Include images in the generated dictfile")
help := pflag.BoolP("help", "h", false, "Show this help text")
pflag.Parse()

Expand Down

0 comments on commit 01da35f

Please sign in to comment.