Skip to content
Snippets Groups Projects
Commit 7caefd33faeb authored by Vincent Hatakeyama's avatar Vincent Hatakeyama
Browse files

:pencil: store version in __version__

parent 60350f857f14
No related branches found
No related tags found
1 merge request!7docker-pg
__version__ = "4.2.1"
__author__ = "XCG Consulting"
# expose some useful functions
from .odoo import odoo_connect_parser, odoo_login # noqa: F401
from .parsing import logging_from_verbose # noqa: F401
......@@ -2,7 +2,6 @@
# vim: set shiftwidth=4 softtabstop=4:
"""Script to run test with local modules
"""
# Version 4.2.1
import logging
import os
import sys
......
......@@ -2,7 +2,6 @@
# vim: set shiftwidth=4 softtabstop=4:
"""Script to locally build a docker image
"""
# Version 4.2.1
import datetime
import json
import logging
......
......@@ -3,7 +3,6 @@
"""Launch a docker image but bind the local directory inside the container
and define the module path automatically.
"""
# Version 4.2.1
import logging
import os
import pwd
......
#!/usr/bin/env python3
"""Imports CSV files into an Odoo server via Odoo import wizard.
"""
# Version 4.2.1
import hashlib
import hmac
import logging
......
#!/usr/bin/env python3
"""Imports CSV files into an Odoo server by using JSONRPC.
"""
# Version 4.2.1
import csv
import logging
import sys
......
#!/usr/bin/env python3
"""Imports CSV files into an Oddo database using SQL.
"""
# Version 4.2.1
import csv
import logging
import sys
......
......@@ -5,6 +5,7 @@
from typing import Optional
import coloredlogs
from odoo_scripts import __version__
def add_verbosity_to_parser(parser: argparse.ArgumentParser):
......@@ -22,7 +23,7 @@
"--quiet",
dest="quiet",
action="count",
help="Decreate verbosity level [default: %(default)s]",
help="Decrease verbosity level [default: %(default)s]",
default=0,
)
......@@ -53,7 +54,12 @@
description=description,
formatter_class=argparse.RawDescriptionHelpFormatter,
)
parser.add_argument("-V", "--version", action="version", version=version)
parser.add_argument(
"-V",
"--version",
action="version",
version="{} [odoo_scripts {}]".format(version, __version__),
)
add_verbosity_to_parser(parser)
return parser
......
......@@ -15,16 +15,6 @@
[bumpversion:file:start]
[bumpversion:file:odoo_scripts/do_tests.py]
[bumpversion:file:odoo_scripts/docker_build.py]
[bumpversion:file:odoo_scripts/docker_dev_start.py]
[bumpversion:file:odoo_scripts/import_base_import.py]
[bumpversion:file:odoo_scripts/import_jsonrpc.py]
[bumpversion:file:odoo_scripts/import_sql.py]
[bumpversion:file:odoo_scripts/__init__.py]
[bumpversion:file:setup.py]
......@@ -29,2 +19,3 @@
[bumpversion:file:setup.py]
......@@ -5,6 +5,7 @@
setup(
name="odoo_scripts",
description="Collection of scripts for Odoo",
version="4.2.1",
long_description=long_description,
long_description_content_type="text/x-rst",
......@@ -49,4 +50,9 @@
},
scripts=[],
python_requires=">=3.6",
url="https://orus.io/xcg/odoo_scripts/",
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
],
)
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