batman
This commit is contained in:
9
ext/id-gen.py
Normal file
9
ext/id-gen.py
Normal file
@@ -0,0 +1,9 @@
|
||||
from json import dumps
|
||||
|
||||
start = 666
|
||||
|
||||
name = {
|
||||
'name': start
|
||||
}
|
||||
|
||||
print(dumps(name))
|
10
ext/name-gen.py
Normal file
10
ext/name-gen.py
Normal file
@@ -0,0 +1,10 @@
|
||||
from datetime import datetime
|
||||
from json import dumps
|
||||
from sys import argv
|
||||
|
||||
name = argv[1]
|
||||
type = argv[2]
|
||||
timestamp = datetime.now().strftime('%d.%m.%Y-%H:%M:%S')
|
||||
name = f'{name}-{type}-{timestamp}'
|
||||
|
||||
print(dumps({'name': name}))
|
2
ext/name-gen.sh
Executable file
2
ext/name-gen.sh
Executable file
@@ -0,0 +1,2 @@
|
||||
#/bin/sh
|
||||
echo {\"name\":\"$1-$2-`date +'%d.%m.%Y-%H:%M:%S'`\"}
|
Reference in New Issue
Block a user