diff options
author | tdro <tdro@users.noreply.github.com> | 2023-10-01 17:14:28 -0400 |
---|---|---|
committer | tdro <tdro@users.noreply.github.com> | 2023-10-01 17:14:28 -0400 |
commit | 4f2f30fe7fa7cf7b7669c1fd90d38b100712b26c (patch) | |
tree | ca4f8615003bfd195f81ad332c06b0bffa5adfdb | |
parent | 5b337aedf01e82c6be4e99f473e47b45c98bcd0a (diff) | |
download | dotfiles-4f2f30fe7fa7cf7b7669c1fd90d38b100712b26c.tar.gz dotfiles-4f2f30fe7fa7cf7b7669c1fd90d38b100712b26c.tar.bz2 dotfiles-4f2f30fe7fa7cf7b7669c1fd90d38b100712b26c.zip |
.local/bin/plumber: Add URL encoding pipe
-rwxr-xr-x | .local/bin/plumber | 4 | ||||
-rwxr-xr-x | .local/bin/plumber-dmenu | 1 |
2 files changed, 5 insertions, 0 deletions
diff --git a/.local/bin/plumber b/.local/bin/plumber index e2c186d..2cf250f 100755 --- a/.local/bin/plumber +++ b/.local/bin/plumber @@ -29,12 +29,16 @@ defmodule ArgParser do reverse_words: "reverse->words", singleline: "text->singleline", slugize: "text->slugize", + urlize: "text->urlize", ] cond do opts[:option] == options[:letterize] -> TextPlumber.firstLetterOfWordsIn(opts[:text]) |> IO.binwrite() + opts[:option] == options[:urlize] -> + URI.encode(opts[:text]) |> IO.binwrite() + opts[:option] == options[:slugize] -> opts[:text] |> String.normalize(:nfd) diff --git a/.local/bin/plumber-dmenu b/.local/bin/plumber-dmenu index bb50a03..f2aa6b6 100755 --- a/.local/bin/plumber-dmenu +++ b/.local/bin/plumber-dmenu @@ -14,6 +14,7 @@ text->jumbleize text->letterize text->singleline text->slugize +text->urlize verse->kjv word->dictionary " |