kostyaesmukov / synctogit Goto Github PK
View Code? Open in Web Editor NEWSyncs Evernote® notes to a git repository in HTML.
Home Page: http://kostyaesmukov.github.io/SyncToGit/
License: MIT License
Syncs Evernote® notes to a git repository in HTML.
Home Page: http://kostyaesmukov.github.io/SyncToGit/
License: MIT License
Traceback (most recent call last):
File "/Users/daniel/miniconda3/envs/synctogit/bin/synctogit", line 8, in <module>
sys.exit(main())
File "/Users/daniel/miniconda3/envs/synctogit/lib/python2.7/site-packages/synctogit/main.py", line 35, in main
run(pargs)
File "/Users/daniel/miniconda3/envs/synctogit/lib/python2.7/site-packages/synctogit/main.py", line 49, in run
while _sync(git, evernote, config, pargs):
File "/Users/daniel/miniconda3/envs/synctogit/lib/python2.7/site-packages/synctogit/main.py", line 67, in _sync
config.set('evernote', 'token', base64.b64encode(token))
File "/Users/daniel/miniconda3/envs/synctogit/lib/python2.7/site-packages/synctogit/Config.py", line 60, in set
self.conf.set(section, key, value)
File "/Users/daniel/miniconda3/envs/synctogit/lib/python2.7/ConfigParser.py", line 396, in set
raise NoSectionError(section)
ConfigParser.NoSectionError: No section: 'evernote'
Hi
I'm running synctogit in a Ubuntu 22.04.4 machine, with git version 2.34.1.
Whem I call synctogit manually from terminal prompt it runs smoothly, but whem I call it from a bash script triggered by cron, I get:
Traceback (most recent call last):
File "/usr/local/bin/synctogit", line 11, in <module>
load_entry_point('synctogit==2.0.1', 'console_scripts', 'synctogit')()
File "/usr/local/lib/python2.7/dist-packages/synctogit/main.py", line 35, in main
run(pargs)
File "/usr/local/lib/python2.7/dist-packages/synctogit/main.py", line 49, in run
while _sync(git, evernote, config, pargs):
File "/usr/local/lib/python2.7/dist-packages/synctogit/main.py", line 78, in _sync
with git.transaction() as t:
File "/usr/local/lib/python2.7/dist-packages/synctogit/GitTransaction.py", line 186, in __enter__
self._check_repo_state()
File "/usr/local/lib/python2.7/dist-packages/synctogit/GitTransaction.py", line 157, in _check_repo_state
self._stash()
File "/usr/local/lib/python2.7/dist-packages/synctogit/GitTransaction.py", line 151, in _stash
if self.git.is_dirty(untracked_files=True):
File "/usr/local/lib/python2.7/dist-packages/git/repo/base.py", line 608, in is_dirty
len(self.git.diff('--cached', *default_args)):
File "/usr/local/lib/python2.7/dist-packages/git/cmd.py", line 466, in <lambda>
return lambda *args, **kwargs: self._call_process(name, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/git/cmd.py", line 934, in _call_process
return self.execute(make_call(), **_kwargs)
File "/usr/local/lib/python2.7/dist-packages/git/cmd.py", line 718, in execute
raise GitCommandError(command, status, stderr_value)
git.exc.GitCommandError: 'git diff --cached --abbrev=40 --full-index --raw' returned with exit code 129
stderr: 'error: unknown option `cached'
usage: git diff --no-index [<options>] <path> <path>
Which seens related to
def _stash(self):
if self.git.is_dirty(untracked_files=True):
self.git.stash('push', '-m', self._get_commit_message())
in GitTransaction.py
Is my perception correct? Do I need to adjust any settings?
pip install synctogit fails (see below)
Environment: Ubuntu 20.04 LTS
Python 3.8.10
pip 20.0.2
pip install synctogit
Collecting synctogit
Downloading synctogit-2.0.1.tar.gz (35 kB)
Collecting oauth2==1.9.0.post1
Using cached oauth2-1.9.0.post1-py2.py3-none-any.whl (25 kB)
Collecting GitPython==2.0.8
Downloading GitPython-2.0.8.tar.gz (407 kB)
|████████████████████████████████| 407 kB 5.8 MB/s
Collecting defusedxml==0.4.1
Downloading defusedxml-0.4.1.tar.gz (48 kB)
|████████████████████████████████| 48 kB 5.4 MB/s
Collecting regex==2016.7.21
Downloading regex-2016.07.21.tar.gz (598 kB)
|████████████████████████████████| 598 kB 11.8 MB/s
Collecting evernote==1.25.2
Downloading evernote-1.25.2.tar.gz (141 kB)
|████████████████████████████████| 141 kB 10.2 MB/s
ERROR: Command errored out with exit status 1:
command: /home/sprickw/PycharmProjects/files_and_database/venv/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-ok46u2sb/evernote/setup.py'"'"'; file='"'"'/tmp/pip-install-ok46u2sb/evernote/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-install-ok46u2sb/evernote/pip-egg-info
cwd: /tmp/pip-install-ok46u2sb/evernote/
Complete output (6 lines):
Traceback (most recent call last):
File "", line 1, in
File "/tmp/pip-install-ok46u2sb/evernote/setup.py", line 6
exec x
^
SyntaxError: Missing parentheses in call to 'exec'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.