Metadata-Version: 2.1
Name: sharelatex
Version: 0.0.2
Summary: UNKNOWN
Home-page: https://gitlab.inria.fr/sed-rennes/sharelatex/synchro-git-sharelatex
Author: sed-rennes
Author-email: sed-rba@inria.fr
License: UNKNOWN
Keywords: sharelatex,client
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: System Administrators
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
Classifier: Operating System :: POSIX :: Linux
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Requires-Dist: socketIO-client (==0.5.7.4)
Requires-Dist: pyyaml (~=5.1.2)
Requires-Dist: click (~=7.0)
Requires-Dist: GitPython (~=2.1.13)
Requires-Dist: filetype (~=1.0.5)

WORK IN PROGRESS: Pull/Push sharelatex project from/to GIT

The code is currently experimental and under development.
Use it with caution.


Installation
------------


.. code:: bash

    # in the future ?
    pip install sharelatex

    # for now
    git clone https://gitlab.inria.fr/sed-rennes/sharelatex/python-sharelatex
    cd python-sharelatex
    pip install [-e] .



Configuration
-------------

.. code:: bash

    echo '
    username: MYLOGIN
    password: MYPASSWORD
    ' > ~/.sharelatex.yaml

    chmod 600 ~/.sharelatex.yaml

Example
-------

Get an existing project on slatex
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. code:: bash

    mkdir test
    cd test
    # download all files of a remote project
    git slatex init <project_id>


Editing and pushing back to slatex
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


.. code:: bash

    # edit your files
    # commit, commit, commit ...
    #
    # Push back your change to sharelatex
    git slatex push


Concurrent updates may occur between your local files (because you changed them)
and the remote ones (because you collaborators changed them). So before pushing,
we try to make sure the merge between the remote copy and the local ones is ok.
You'll have to resolve the conflict manually (as usual with Git) and attempt a
new push.

Create a remote project from a local git
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. code:: bash

   git slatex new <name>


