Skip to content

Commit

Permalink
feature: added new ipsums
Browse files Browse the repository at this point in the history
  • Loading branch information
404answernotfound committed May 29, 2023
1 parent a5061ed commit 27e6d5f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Formula/loremclipsum.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ class Loremclipsum < Formula
desc "A CLI tool to copy-paste lorem ipsum text in different flavors."
homepage "https://github.com/Schrodinger-Hat/loremclipsum"
url "https://github.com/Schrodinger-Hat/loremclipsum/raw/main/loremclipsum.tar.gz"
sha256 "20c7ed1b28483d9434f3f01f0568a2813bba9733cc4fa768ff7ce073df5c7fa4"
version "1.0.0"
sha256 "83e57ff423a36eb961fda2c073f65ed0edfa96c6755a4311b03d911cad6607c8"
version "1.0.1"
license "MIT"

def install
Expand Down
Binary file modified loremclipsum.tar.gz
Binary file not shown.
4 changes: 3 additions & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ fn main() {
let args = Cli::parse();
let mut ctx: ClipboardContext = ClipboardProvider::new().unwrap();

let valid_ipsum = ["lorem", "bacon", "cat", "hipster", "zombie"];
let valid_ipsum = ["lorem", "bacon", "cat", "hipster", "zombie", "delorean", "pirate"];

if !valid_ipsum.contains(&args.ipsum.as_str()) {
println!(
Expand Down Expand Up @@ -49,6 +49,8 @@ fn generate_ipsum(num_paragraphs: u8, ipsum_type: &str) -> String {
"bacon" => Some(ipsums::BACON_IPSUM.to_string()),
"hipster" => Some(ipsums::HIPSTER_IPSUM.to_string()),
"zombie" => Some(ipsums::ZOMBIE_IPSUM.to_string()),
"delorean" => Some(ipsums::DELOREAN_IPSUM.to_string()),
"pirate" => Some(ipsums::PIRATE_IPSUM.to_string()),
_ => None,
};

Expand Down

0 comments on commit 27e6d5f

Please sign in to comment.