Skip to content
Snippets Groups Projects
Commit 4d012e66 authored by BRONES Romain's avatar BRONES Romain
Browse files

Add setup script

* rename directory bin to script
* remove older deploy script
* Configuration are installed as package files
parent 91cc8031
No related branches found
No related tags found
No related merge requests found
Pipeline #3232 failed
__version__ = "AUTOVERSIONREPLACE"
__version__ = "2.2"
README 0 → 120000
README.adoc
\ No newline at end of file
#!/bin/bash
echo "Deploy module and CLI in RCM environment"
# Get the current version
version=$(git describe --tags)
# Copy Python module
ipath=/home/operateur/.local/lib/python3.6/site-packages/FofbTool
mkdir -p $ipath
cp FofbTool/*.py $ipath/ -rvf
cp FofbTool/*.cfg $ipath/ -rvf
# Copy bin CLI
cp bin/FofbTool /home/production/scripts/DG/python/bin/ -vf
# Put exec rights
chmod +x /home/production/scripts/DG/python/bin/FofbTool
# AWK the __init__.py file to replace the version variable
awk -v version="$version" '{ gsub("AUTOVERSIONREPLACE",version) ; print}' FofbTool/__init__.py > $ipath/__init__.py
File moved
setup.py 0 → 100755
#!/usr/bin/env python
from distutils.core import setup
setup(name='FofbTool',
version='2.2',
description='Python module to operate and configure SOLEIL FOFB.',
url='https://gitlab.synchrotron-soleil.fr/dg/fofb/fofbtool',
license="GNU-GPL-v3",
author='Romain BRONÈS',
author_email='romain.brones@synchrotron-soleil.fr',
packages=['FofbTool',],
scripts=['scripts/FofbTool',],
package_data={
'FofbTool': ['*.cfg'],
},
install_requires = ['pytango>=9.2', 'numpy>=1.15'],
)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment