Get NFL/MLB Scores/Time

w3m -no-cookie http://m.espn.go.com/nfl/scoreboard?|sed 's/ Final/ : Final/g'|sed 's/ F\// : F\//g'|sed 's/, / : /g'|grep -i ':'
change the nfl in the url to mlb or nba to get those score/times as well
Sample Output
Thursday : November 11
BAL 21 ATL 26 : Final
Sunday : November 14
DET 12 BUF 14 : Final
MIN 13 CHI 27 : Final
NYJ 26 CLE 20 : F/OT
CIN 17 IND 23 : Final
TEN 17 MIA 29 : Final
CAR 16 TB 31 : Final
HOU 24 JAC 31 : Final
KC 29 DEN 49 : Final
DAL 33 NYG 20 : Final
SEA 36 ARI 18 : Final
STL 20 SF 23 : F/OT
NE at PIT 8:20 PM : NBC
Monday : November 15
PHI at WSH 8:30 PM : ESPN

2
By: SQUIIDUX
2010-11-15 01:18:19

These Might Interest You

  • In the above example all files have 4 lines. In "file1" consecutive lines are: "num, 1, 2, 3", in "file2": "name, Jack, Jim, Frank" and in "file3": "scores, 1300, 1100, 980". This one liner can save considerate ammount of time when you're trying to process serious portions of data. "-d" option allows one to set series of characters to be used as separators between data originating from given files. Show Sample Output


    8
    paste -d ',:' file1 file2 file3
    thebodzio · 2009-06-17 00:11:04 5

  • 1
    utime(){ python -c "import time; print(time.strftime('%a %b %d %H:%M:%S %Y', time.localtime($1)))"; }
    4Aiur · 2010-05-14 08:00:44 0
  • Adds the time in 12hr AM/PM format to the beginning of a prompt. Change \@ to \t for 24-hour time or \T for 12hr without AM/PM. To keep the time the next time you open a terminal, edit ~/.bashrc and stick the command at the bottom. Show Sample Output


    1
    export PS1="(\@) $PS1"
    cmdq · 2010-11-22 04:50:21 0
  • the --time-style argument to 'ls' takes several possible modifiers: full-iso, long-iso, iso, locale, +FORMAT. The +FORMAT modifier uses the same syntax as date +FORMAT. --time-style=+"%Y-%m-%d %H:%M:%S" strikes a happy medium between accuracy and verbosity: ls -lart --time-style=long-iso doesn't show time down to the nearest second, ls -lart --time-style=full-iso displays time to 10E-9 second resolution, but with no significant digits past the full seconds, also showing the timezone: -rw-r--r-- 1 bchittenden bchittenden 0 2011-02-10 12:07:55.000000000 -0500 bar Show Sample Output


    4
    ls -l --time-style=+"%Y-%m-%d %H:%M:%S"
    bartonski · 2011-02-10 17:15:37 2

What Others Think

Add '|column -t' at the end for a nicer layout.
houghi · 396 weeks and 4 days ago
nice i like that, thank you for the addition
SQUIIDUX · 396 weeks and 4 days ago
this command is old now.
SQUIIDUX · 328 weeks and 6 days ago

What do you think?

Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?

You must be signed in to comment.

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands



Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: