Commit 2862eef8 authored by Vincent's avatar Vincent

Clarify how to contibute

Fixes #3.
parent a939ce7b
Pipeline #25529471 passed with stage
in 1 minute and 48 seconds
# WhereIsSciHub
A barebones Node.js app using [Express 4](
Fetches the URLs currently [listed on WikiData as working for Sci-Hub](,
and hosts a webpage listing those URLs (and a service to automatically redirect the visitor to those URLs at `/go`).
Try it out at
## Running Locally
Make sure you have [Node.js]( and the [Heroku CLI]( installed.
Make sure you have [Node]( installed.
$ git clone # or clone your own fork
......@@ -15,23 +17,30 @@ $ npm start
Your app should now be running on [localhost:5000](http://localhost:5000/).
## Deploying to Heroku
## Deploying to
You can deploy it to []( using the following command.
Note that you need your own account there (you will be asked to create one when
running the command), and that it will be deployed to a separate subdomain.
$ heroku create
$ git push heroku master
$ heroku open
$ npx now
[![Deploy to Heroku](](
(`npx` [is provided by the Node package manager](
## Navigating the source code
## Documentation
The app is written in Javascript and is really quite simple. It consists of a
single file, [index.html](/index.html). The meat of the application is the
function `getUrls` at the bottom of the file, which fetches the current Sci-Hub
URLs from WikiData (using [SPARQL](
For more information about using Node.js on Heroku, see these Dev Center articles:
It also starts a small web server using [Express](, to
serve the following endpoints:
- [Getting Started with Node.js on Heroku](
- [Heroku Node.js Support](
- [Node.js on Heroku](
- [Best Practices for Node.js Development](
- [Using WebSockets on Heroku with Node.js](
- `/favicon.ico` - the [Favicon](
- `/api` - providing the list of URLs as [JSON](
- `/go` - directly redirect the user to the URL currently listed on WikiData as preferred
- `/go/*` - directly redirect the user to the preferred URL, passing on anything beind `/go/` to that URL. This allows users to e.g. directly append a DOI or a link to an article to find it on Sci-Hub.
- `/` - a simple HTML page listing the URLs for human consumption, and providing links to e.g. this source code :)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment