Skip to content

Commit

Permalink
v0
Browse files Browse the repository at this point in the history
  • Loading branch information
denkiwakame committed Jun 7, 2021
0 parents commit 346e290
Show file tree
Hide file tree
Showing 20 changed files with 6,242 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: build
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: "14.17.0"
- name: install
run: npm install
- name: build
run: npm run build
- name: pack
run: npm run pack
24 changes: 24 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Releases
on:
push:
tags:
- "*"

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: "14.17.0"
- name: install
run: npm install
- name: build
run: npm run build
- name: pack
run: npm run pack
- uses: ncipollo/release-action@v1
with:
artifacts: "packages/*"
token: ${{secrets.GITHUB_TOKEN}}
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules/
dist/
60 changes: 60 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# arxiv2notion
[![build](https://github.com/denkiwakame/arxiv2notion/actions/workflows/build.yaml/badge.svg)](https://github.com/denkiwakame/arxiv2notion/actions/workflows/build.yaml)

Easy-to-use arXiv clipper for [Notion](https://www.notion.so) based on [Notion API](https://developers.notion.com/)

![demo](doc/arxiv2notion.gif)

## Getting Started
- login to [notion.so](https://www.notion.so) by admin user
- create databases where you save arXiv articles
- *add properties listed below.* `Title` `URL` `Publisher` `Authors` `Abstract`
- note that you should create *extactly the same properties with listed names.*

|property|type|
|-----|-----|
|Title|Text|
|URL|URL|
|Publisher|Select|
|Authors|Text|
|Abstract|Text|

- follow the instruction of [Notion API](https://developers.notion.com/docs/getting-started)
- navigate to [My Integrations](https://www.notion.so/my-integrations)
- `+ New integration`
- associated workspace: select your workspace where you save arXiv articles
- invite the integration to target databases via `Share` -> `Invite`

![ref1](doc/notion.png)

## Installation
- download extension package from https://github.com/denkiwakame/arxiv2notion/releases
- for Chrome, navigate to `chrome://extension`
- drag and drop the extension from your file manager anywhere onto the extensions page
- or unzip the extension and `load unpacked` in developer mode

## Setup
- right-click on the extension icon > `Options`
- copy *integration id* (not the secret token! see figures below) from https://www.notion.so/my-integrations/internal/${integration-id}
- paste the `integration id` and click on `+` button.
- if your entered id is valid, you can see the following callback messages.

```
In order to avoid storing Notion API key directoly onto chrome local storage,
arxiv2notion requests API token on-demand via integration ID when you are logged in.
Note that you must be logged in to notion.so when you use this extension.
```

![ref2](doc/integrataion.png)

![ref3](doc/option.png)

## Build locally (for Developers)

```bash
$ git clone https://github.com/denkiwakame/arxiv2scrap.git
$ npm install
$ npm run build
$ npm run watch # debug locally
$ npm run pack # packaging to zip
```
Binary file added doc/arxiv2notion.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/integrataion.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/notion.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/option.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 27 additions & 0 deletions manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"manifest_version": 2,
"name": "arxiv2notion",
"description": "easy-to-use arXiv clipper for notion.so",
"version": "0.0",
"icons": {
"128": "icon128.png"
},
"browser_action": {
"default_popup": "popup.html",
"default_icon": {
"128": "icon128.png"
}
},
"options_ui": {
"page": "options.html",
"open_in_tab": false
},
"permissions": [
"<all_urls>",
"*://api.notion.com/*",
"*://www.notion.so/*",
"storage",
"tabs"
],
"content_security_policy": "script-src 'self' 'unsafe-eval'; object-src 'self'"
}
Loading

0 comments on commit 346e290

Please sign in to comment.