-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
15 lines (11 loc) · 955 Bytes
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
Straight to the point:
1. Find a page you like in Wikiquote, in my case BSG page: http://en.wikiquote.org/wiki/Battlestar_Galactica_%282003%29
2. Choose a name for your fortune file, in my case, bsg_fortune
3. Run the program: ./wikiquote2fortune http://en.wikiquote.org/wiki/Battlestar_Galactica_%282003%29 > bsg_fortune
4. strfile bsg_fortune
5. All ready. Just run fortune bsg_fortune, and everything should be ok.
Step 4 (strfile) will create a file called bsg_fortune.dat. Those two files must be in the same folder for the fortune command to work.
Note: I developed this code while some tests for my app were running, so there might be bugs...
Note 2: I don't work with shell script daily so probably there's a better way of doing that. Contribute if you know how...
Note 3: I quickly redid it `go` as the previous one was not working as expected...
Enjoy, MIT licensed (c'mon it's just a handful of lines...) [After so many years it still is]