> Browse your favorite subreddits painlessly
Browse your favorite subreddits painlessly
You visit your favorite subreddit and you notice that it’s full of new posts. If you want to check them all, you need to click on each post. How to open all these posts in new tabs?
I made a little Python script for solving this problem (available here, in the folder “reddit”). Just specify a subreddit and what to extract (comment links [
-c switch] or direct URLs [
-u switch]). The script will list the available links. With another script of mine you can open these links in Firefox.
./reddit_get_posts.py -c /r/earthporn
Get links to comments of subreddit “earthporn”.
./reddit_get_posts.py -u /r/earthporn
Get links to direct URLs of subreddit “earthporn”.
./reddit_get_posts.py -u http://www.reddit.com/r/earthporn
You can specify the complete URL of the subreddit.
./reddit_get_posts.py -u http://www.reddit.com/r/EarthPorn/?count=25&after=t3_jffyd
You can even browse pages on reddit.com.
Extract links of your favourite subreddit (specify it with the constant DEFAULT_REDDIT).
This script can be used together with another script of mine called open_in_tabs.py, which
is part of this Bash-Utils project too. open_in_tabs.py can open the extracted links in
your Firefox instance. Example:
./reddit_get_posts.py -u /r/earthporn | open_in_tabs -s
This will open the links simultaneously (
-s switch) in Firefox.