esapy
A python implementation of esa.io API
The main purpose of this package is implementation of easy uploading and sharing jupyter notebook to esa.io service.

Description in Japanese: https://esa-pages.io/p/sharing/14661/posts/184/d983bd2e71ad35528500.html
INSTALATION
-
Install package
$pip install esapy
-
set credentials (for esa.io)
-
generate esa.io token with read/write permission.
-
make configuration in your environment variables
Environment variables: ESA_PYTHON_TOKEN, ESA_PYTHON_TEAM.
You can check your token using esa config from command line.
-
set credentials (for growi)
-
generate token
-
set environment variables
- GROWI_URL
- GROWI_TOKEN
HOW TO USE
-
Prepare .ipynb file
-
Upload your notebook
$ esa up target.ipynb
This package uploads images, and uploads markdown file as a new post or update the previously uploaded post.
-
access the new post and edit.
If process fails due to a network problem, you can check by esa stats.
Whether an ipynb file has been already uploaded can be checked by esa ls <filepath or dirpath>.
For list up all notebooks recursively, esa ls --recursive.
DOCUMENT
commands
This package registers following command line tools.
(deprecated) config file
Use environment variable instead of config file.
The config file (~/.esapyrc) should be written in yaml format.
An example is shown below.
token: your_token
team: your_team
TIPS
Combination with fuzzy finders like fzf is useful.
For example,
alias esafu='esa up --no-browser "$(esa ls | fzf | sed -r "s/(.+)\\| (.+)/\\2/")"'
INSTALLATION for DEVELOPMENT
- setup poetry on your environment
- clone this repository
- cd repo directory
poetry install
git checkout develop
For Growi adminitorator
Allow details tag and open attribute by configuration.
Allow guest user access by security configuration. Some APIs have bug related to authentication.
LICENSE
Copyright (c) 2020 Kosuke Mizuno
This package is released under the MIT license (see LICENSE file).