HackerNews and Reddit in one placce

Overview

EDIT: this project is 3.5 years old. I found it sad it's just laying around, so I did some minimal fixes and deployed it. Hope you enjoy! (PR's welcome)

HackerReddit

I love both HackerNews and Reddit. They both have a fast, minimalist website design, they both have great communities and great content.

So, my project is to have a unified way of viewing these two!

How it works: By default, you will see a mix of top HN posts and posts of a few default subreddits, all mixed in the same page. If you wish to sign up, you can also customize the list of subreddits that will appear on your frontpage. Future: You will also be able to weight different news sources according to your preferences. E.g. give Hackernews a weight of 0.5x, and /r/cats maybe a 2x)

Of course, you can navigate to the original HN/Reddit post at any time by simply clicking the comment section. You can also view the profile of the author or the link itself. Most other text is also interactable, e.g. you can go to the original subreddit, or check out all HN posts on that specific domain, etc...

Future Improvements:

  • additional news-sources (e.g. RSS-feeds)
  • custom weighing of news sources/subreddits (user-chosen weights)
  • upvote functionality directly from HackerReddit using Oauth2
  • automatically subscribe to subreddits when authenticating with Reddit account

Files:

Under /templates are all the html templates:

  • layout.html: layout file, extends all other files. Navbar, login functionality, footer

  • index.html: newsfeed

  • error.html: errorhandler

  • login.html: Login as well as registering functionality

  • ...

  • /static you can find the images and css stylesheets and js files

  • /logs logs are stored here

  • data.db: database (SQLite)

  • requirements.txt: Python dependencies

  • util.py: Utilities module, takes care of handling the API's and loading the data

  • config.py: Configuration file

Architecture

Since getting the data from HN/Reddit every time a user loads the website is way too slow, we have to cache the data in our own database. For this, every 5 minutes we get the top 50 Hackernews stories as well as the top 10 reddit stories in every subreddit that our users are subscribed to.

Also, when a user subscribes to a subreddit that is not cached, we launch a new update request for that specific subreddit.

You might also like...
Shred your reddit comment and post history

trasheddit Shred your reddit comment and post history (x89/Shreddit replacement) Usage Simple Example Download trasheddit: git clone https://github.co

A small bot to interact with the reddit API. Get top viewers and update the sidebar widget.

LiveStream_Reddit_Bot Get top twitch and facebook stream viewers for a game and update the sidebar widget and old reddit sidebar to show your communit

A bot framework for Reddit to manage threads, wiki pages, widgets, menus and more.

Sub Manager Sub Manager is a bot framework for Reddit to automate a variety of tasks on one or more subreddits, and can be configured and run without

A Python package that can be used to download post and comment data from Reddit.

Reddit Data Collector Reddit Data Collector is a Python package that allows a user to collect post and comment data from Reddit. It is built on top of

A Python script that exports users from one Telegram group to another using one or more concurrent user bots.

ExportTelegramUsers A Python script that exports users from one Telegram group to another using one or more concurrent user bots. Make sure to set all

Source code of u/pekofy_bot from reddit.

pekofy-bot Source code of u/pekofy_bot from reddit. Get more info about the bot here: https://www.reddit.com/user/pekofy_bot/comments/krxxol/pekofy_bo

historical code from reddit.com

This repository is archived. This repository is archived and will not receive any updates or accept issues or pull requests. To report bugs in reddit.

A way to export your saved reddit posts to a Notion table.
A way to export your saved reddit posts to a Notion table.

reddit-saved-to-notion A way to export your saved reddit posts and comments to a Notion table.Uses notion-sdk-py and praw for interacting with Notion

Reddit cli to slack at work

Reddit CLI (v1.0) Introduction Why Reddit CLI? Coworker who sees me looking at something in a browser: "Glad you're not busy; I need you to do this, t

Owner
Hugo Montenegro
Currently finishing my bachelors @Harvard and exploring a few side projects.
Hugo Montenegro
PRAW, an acronym for "Python Reddit API Wrapper", is a python package that allows for simple access to Reddit's API.

PRAW: The Python Reddit API Wrapper PRAW, an acronym for "Python Reddit API Wrapper", is a Python package that allows for simple access to Reddit's AP

Python Reddit API Wrapper Development 3k Dec 29, 2022
PRAW, an acronym for "Python Reddit API Wrapper", is a python package that allows for simple access to Reddit's API.

PRAW: The Python Reddit API Wrapper PRAW, an acronym for "Python Reddit API Wrapper", is a Python package that allows for simple access to Reddit's AP

Python Reddit API Wrapper Development 3k Dec 29, 2022
A reddit bot that imitates the popular reddit bot "u/repostsleuthbot" to trick people into clicking on a rickroll

Reddit-Rickroll-Bot A reddit bot that imitates the popular reddit bot "u/repostsleuthbot" to trick people into clicking on a rickroll Made with The Py

null 0 Jul 16, 2022
One version package to rule them all, One version package to find them, One version package to bring them all, and in the darkness bind them.

AwesomeVersion One version package to rule them all, One version package to find them, One version package to bring them all, and in the darkness bind

Joakim Sørensen 39 Dec 31, 2022
Mini Tool to lovers of debe from eksisozluk (one of the most famous website -reffered as collaborative dictionary like reddit- in Turkey) for pushing debe (Most Liked Entries of Yesterday) to kindle every day via Github Actions.

debe to kindle Mini Tool to lovers of debe from eksisozluk (one of the most famous website -refered as collaborative dictionary like reddit- in Turkey

null 11 Oct 11, 2022
Track live sentiment for stocks from Reddit and Twitter and identify growing stocks

Market Sentiment About This repository can mainly be used for two things. a. Tracking the live sentiment of stocks from Reddit and Twitter b. Tracking

Market Sentiment 345 Dec 17, 2022
See trending stock tickers on Reddit and check Stock perfomance

See trending stock tickers on Reddit and check Stock perfomance

Abbas 1.5k Jan 6, 2023
Twitter bot that turns comment chains into ace attorney scenes. Inspired by and using https://github.com/micah5/ace-attorney-reddit-bot

Ace Attorney twitter Bot Twitter bot that turns comment chains into ace attorney scenes. Inspired by and using https://github.com/micah5/ace-attorney-

Luis Mayo Valbuena 542 Dec 17, 2022
Exports saved posts and comments on Reddit to a csv file.

reddit-saved-to-csv Exports saved posts and comments on Reddit to a csv file. Columns: ID, Name, Subreddit, Type, URL, NoSFW ID: Starts from 1 and inc

null 70 Jan 2, 2023
Create Fast and easy image datasets using reddit

Reddit-Image-Scraper Reddit Reddit is an American Social news aggregation, web content rating, and discussion website. Reddit has been devided by topi

Wasin Silakong 4 Apr 27, 2022