Commit graph

13 commits

Author SHA1 Message Date
Nick Sweeting
b3c1cb716e
move abx plugins inside vendor dir 2024-10-28 04:07:35 -07:00
Nick Sweeting
b3107ab830
move final legacy config to plugins and fix archivebox config cmd and add search opt 2024-10-21 02:56:00 -07:00
Nick Sweeting
18474f452b
move config moved out of legacy files and better version output 2024-09-30 23:52:00 -07:00
Nick Sweeting
363a499289
move util.py into misc folder 2024-09-30 17:25:15 -07:00
Nick Sweeting
dfca4b13b2
move system.py into misc folder 2024-09-30 17:13:55 -07:00
Nick Sweeting
3e5b6ddeae
move config into dedicated global app 2024-09-30 15:59:05 -07:00
Nick Sweeting
bb65b2dbec
move almost all config into new archivebox.CONSTANTS 2024-09-25 05:10:09 -07:00
Nick Sweeting
2c2d034d6d
move to new vendoring fallback logic 2024-08-23 02:01:02 -07:00
Nick Sweeting
44f5338470
fix typo in pocket_api articl variable name 2021-11-12 19:23:47 -05:00
Bruno Tavares
bb2a2e758a
Avoid KeyError on Pocket API parser
When trying to import my pocket library I got a lot of ` KeyError`  on Python. Pocket API has a few idiosyncrasies, such as sometimes returning the keys on json, sometimes not.

` ` ` sh
archivebox add --parser pocket_api pocket://my_username
` ` ` 

Gave me this errors
` ` ` 
  File "/app/archivebox/parsers/pocket_api.py", line 54, in link_from_article
    title = article['resolved_title'] or article['given_title'] or url
KeyError: 'resolved_title'
` ` ` 

This commit are the patches I've changed to successfully import my library
2021-09-07 21:53:36 -03:00
Nick Sweeting
8ce93ff787 use KEY, NAME, and PARSER to define parsers instead of hardcoding in init 2021-03-31 01:05:49 -04:00
Nick Sweeting
a0a79cead8 move utils and vendored libs into subfolders 2020-12-06 02:01:18 +02:00
mAAdhaTTah
ac7ad9e942
Add parser for Pocket API
Pass a url like `pocket://Username` to import that username's archived Pocket
library. Tokens need to be stored in ArchveBox.conf with the following keys:

```
POCKET_CONSUMER_KEY = key-from-custom-pocket-app
POCKET_ACCESS_TOKENS = {"YourUsername": "pocket-token-for-app"}
```

`POCKET_ACCESS_TOKENS` MUST be on a single line, or the JSON will be
misinterpreted by the parser as a new key/value pair.
2020-12-04 22:54:39 -05:00