Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Rapid Prototyping Lab
Python Modules
obelixtools
Commits
8d419412
Commit
8d419412
authored
Oct 05, 2019
by
Christian Lölkes
Browse files
Version 1.1.0
parent
33468c1d
Changes
4
Hide whitespace changes
Inline
Side-by-side
CHANGELOG
View file @
8d419412
...
...
@@ -6,5 +6,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]
## [1.0.0] 2019-10-
7
## [1.0.0] 2019-10-
4
- Initial release
## [1.1.0] 2019-10-5
### Added
- Run the module directly with python -m obelixtools
obelixtools/__init__.py
View file @
8d419412
...
...
@@ -141,11 +141,3 @@ class API(object):
def
human_readable
(
bytes
,
units
=
[
' bytes'
,
'KB'
,
'MB'
,
'GB'
,
'TB'
,
'PB'
,
'EB'
]):
""" Returns a human readable string reprentation of bytes"""
return
str
(
bytes
)
+
units
[
0
]
if
bytes
<
1024
else
human_readable
(
bytes
>>
10
,
units
[
1
:])
if
__name__
==
'__main__'
:
logging
.
basicConfig
(
level
=
logging
.
INFO
)
logger
.
info
(
'Script is executed as standalone file.'
)
test
=
API
()
test
.
checkConnection
()
test
.
speedtest
()
obelixtools/__main__.py
0 → 100644
View file @
8d419412
from
.
import
API
import
logging
logging
.
basicConfig
(
format
=
'%(asctime)s - %(name)s - %(levelname)s: %(message)s'
,
datefmt
=
'%d-%b-%y %H:%M:%S'
,
level
=
logging
.
INFO
)
if
__name__
is
'__main__'
:
logger
=
logging
.
getLogger
(
__name__
)
test
=
API
()
test
.
checkConnection
()
test
.
speedtest
()
setup.py
View file @
8d419412
...
...
@@ -5,7 +5,7 @@ with open('README.md', 'r') as fh:
setuptools
.
setup
(
name
=
'obelixtools'
,
version
=
'1.
0
.0'
,
version
=
'1.
1
.0'
,
author
=
'Christian Lölkes'
,
author_email
=
'christian.loelkes@gmail.com'
,
description
=
'Useful tools I need in many projects.'
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment