parent
817f7816c6
commit
0c9f1f377d
@ -0,0 +1,11 @@
|
|||||||
|
sayings/squishy.txt
|
||||||
|
sayings/love.txt
|
||||||
|
sayings/programming.txt
|
||||||
|
sayings/special-melly.txt
|
||||||
|
sayings/generic.txt
|
||||||
|
sayings/food.txt
|
||||||
|
sayings/blind.txt
|
||||||
|
sayings/sex.txt
|
||||||
|
sayings/quote.txt
|
||||||
|
sayings/music.txt
|
||||||
|
sayings/techies.txt
|
@ -0,0 +1,6 @@
|
|||||||
|
It's a good thing you do not like me for my looks!
|
||||||
|
Shove this cane up your ass!
|
||||||
|
Your energy bill will always be lower than mine.
|
||||||
|
Read my pimples, see if they speak to you!
|
||||||
|
Follow me!
|
||||||
|
Don't forget your cane, idiot!
|
@ -0,0 +1,7 @@
|
|||||||
|
We should go feed eachother cheese at the beach.
|
||||||
|
Let's watch a movie, your choice!
|
||||||
|
I want to squish your face!
|
||||||
|
I want to eat you, like a cheese ball!
|
||||||
|
I want to boop your nose!
|
||||||
|
Let's go work out together!
|
||||||
|
🤍💛!
|
@ -0,0 +1,5 @@
|
|||||||
|
"You miss 100% of the shots you don't take"--Wayne Gretzky
|
||||||
|
"Money money money money!"--Mr. Krabs
|
||||||
|
"You could make a religion out of this!"--Bill Wurtz
|
||||||
|
"Be as humble as myself."--Kenye West
|
||||||
|
"Don't be a pussy!"--Tait
|
@ -0,0 +1,6 @@
|
|||||||
|
If you don't make love to the coconut song, have you even lived?
|
||||||
|
Lick it; suck it; twist it; pull it!
|
||||||
|
JUST DO IT!
|
||||||
|
Can prostitutes work from home? And would it be over Zoom?
|
||||||
|
"My cock is community property!"
|
||||||
|
Happy D
|
@ -1,2 +1,8 @@
|
|||||||
Smelly Melly!
|
Smelly Melly!
|
||||||
belly, button
|
belly, button
|
||||||
|
Melly, button
|
||||||
|
Free dorm food!
|
||||||
|
Let's go to Kelly's!
|
||||||
|
Let's go to the cheese store!
|
||||||
|
Let's go watch the sunset at the dock.
|
||||||
|
If I'm far away, just remember, I can't see you right now either.
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
I'd like to peek at every one of your directories.
|
I'd like to peek at every one of your directories.
|
||||||
unzip; strip; touch; grep; mount; fsck; yes; more; fsck; fsck; umount; clean; sleep;
|
unzip; strip; touch; grep; mount; fsck; yes; more; fsck; fsck; umount; clean; sleep;
|
||||||
Run `curl https://melody-214.tait.tech` for more info funny sayings
|
Run `curl https://melody-214.tait.tech` for more!
|
||||||
|
nmcli dev wifi connect tait
|
||||||
|
@ -1,11 +1,6 @@
|
|||||||
use lazy_static;
|
use crate::sayings::read_all_sayings as s;
|
||||||
use crate::sayings::read_all_sayings;
|
use std::sync::Mutex as M;
|
||||||
use std::sync::Mutex;
|
|
||||||
|
|
||||||
lazy_static! {
|
lazy_static! {
|
||||||
static ref SAYINGS: Mutex<Vec<String>> = Mutex::new(read_all_sayings());
|
static ref SAYINGS:M<Vec<String>> = M::new(s());
|
||||||
}
|
|
||||||
|
|
||||||
pub fn all_sayings() -> Vec<String> {
|
|
||||||
SAYINGS.lock().expect("Error locking SAYINGS.").to_vec()
|
|
||||||
}
|
}
|
||||||
|
pub fn all_sayings()->Vec<String>{SAYINGS.lock().expect("lock err").to_vec()}
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
extern crate rand;
|
|
||||||
use rand::thread_rng;
|
|
||||||
use crate::all_sayings::all_sayings;
|
|
||||||
use crate::choose_saying::rand::prelude::IteratorRandom;
|
|
||||||
|
|
||||||
pub fn random_saying() -> String {
|
|
||||||
let mut rng = thread_rng();
|
|
||||||
all_sayings().iter().choose(&mut rng).expect("Error getting random saying.").to_string()
|
|
||||||
}
|
|
@ -0,0 +1,8 @@
|
|||||||
|
use crate::env;
|
||||||
|
use crate::get_lines;
|
||||||
|
|
||||||
|
/// Gets the list of all files to load sayings from.
|
||||||
|
/// Panics on any kind of possible error
|
||||||
|
pub fn get_files() -> Vec<String> {
|
||||||
|
return get_lines::get_lines(env::gcf());
|
||||||
|
}
|
@ -0,0 +1,9 @@
|
|||||||
|
use std::fs;
|
||||||
|
|
||||||
|
pub fn get_lines(file_name: String) -> Vec<String> {
|
||||||
|
fs::read_to_string(file_name)
|
||||||
|
.expect("Error reading some file")
|
||||||
|
.lines()
|
||||||
|
.map(|x| x.to_string())
|
||||||
|
.collect()
|
||||||
|
}
|
@ -1,7 +1,8 @@
|
|||||||
pub mod saying_files;
|
|
||||||
pub mod env;
|
pub mod env;
|
||||||
pub mod ns;
|
/// All rise and hail the great pseudo-random number generator code!
|
||||||
pub mod choose_saying;
|
pub mod randoms;
|
||||||
pub mod sayings;
|
pub mod sayings;
|
||||||
pub mod all_sayings;
|
pub mod all_sayings;
|
||||||
|
pub mod get_lines;
|
||||||
|
pub mod get_files;
|
||||||
#[macro_use] extern crate lazy_static;
|
#[macro_use] extern crate lazy_static;
|
||||||
|
@ -1,14 +1,8 @@
|
|||||||
#[macro_use]
|
#[macro_use]
|
||||||
extern crate rocket;
|
extern crate rocket;
|
||||||
extern crate lazy_static;
|
extern crate lazy_static;
|
||||||
use melly_valentines::choose_saying::random_saying;
|
use melly_valentines::randoms::random_saying;
|
||||||
|
|
||||||
#[get("/")]
|
#[get("/")]
|
||||||
fn a() -> String {
|
fn a()->String{random_saying()}
|
||||||
random_saying()
|
|
||||||
}
|
|
||||||
|
|
||||||
#[launch]
|
#[launch]
|
||||||
fn rocket() -> _ {
|
fn rocket()->_{rocket::build().mount("/",routes![a])}
|
||||||
rocket::build().mount("/", routes![a])
|
|
||||||
}
|
|
||||||
|
@ -1,3 +0,0 @@
|
|||||||
pub fn new_saying() -> String {
|
|
||||||
return "Helo!".to_string();
|
|
||||||
}
|
|
@ -0,0 +1,7 @@
|
|||||||
|
use rand::thread_rng;
|
||||||
|
use crate::all_sayings::all_sayings;
|
||||||
|
use rand::prelude::IteratorRandom;
|
||||||
|
|
||||||
|
pub fn random_saying() ->String{
|
||||||
|
all_sayings().iter().choose(&mut thread_rng()).expect("saying error").to_string()
|
||||||
|
}
|
@ -1,10 +0,0 @@
|
|||||||
use std::fs;
|
|
||||||
use crate::env::gcf;
|
|
||||||
|
|
||||||
pub fn get_files() -> Vec<String> {
|
|
||||||
fs::read_to_string(gcf())
|
|
||||||
.expect("Error reading core file")
|
|
||||||
.lines()
|
|
||||||
.map(|x| x.to_string())
|
|
||||||
.collect()
|
|
||||||
}
|
|
@ -1,9 +1,6 @@
|
|||||||
use crate::saying_files::get_files;
|
use crate::get_files::get_files;
|
||||||
|
use crate::get_lines::get_lines;
|
||||||
|
|
||||||
pub fn read_all_sayings() -> Vec<String> {
|
pub fn read_all_sayings()-> Vec<String>{
|
||||||
get_files()
|
get_files().iter().map(|n| n.lines().map(|l| get_lines(l.to_string()))).flatten().flatten().collect()
|
||||||
.iter()
|
|
||||||
.map(|n| n.lines().map(|l| l.to_string()))
|
|
||||||
.flatten()
|
|
||||||
.collect()
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in new issue