Test changing of update_check_interval on the CI server
This commit is contained in:
parent
a75d075dd1
commit
d12a4b0a1a
@ -13,7 +13,7 @@ jobs:
|
|||||||
- run: python3 test.py
|
- run: python3 test.py
|
||||||
- run: make FAIL_WARN=-W man
|
- run: make FAIL_WARN=-W man
|
||||||
- run: make FAIL_WARN=-W html
|
- run: make FAIL_WARN=-W html
|
||||||
- run: python3 setup.py linux-package
|
- run: python3 setup.py linux-package --update-check-interval=0
|
||||||
|
|
||||||
lin-35:
|
lin-35:
|
||||||
docker:
|
docker:
|
||||||
|
|||||||
13
setup.py
13
setup.py
@ -657,12 +657,13 @@ def package(args, for_bundle=False, sh_launcher=False):
|
|||||||
|
|
||||||
shutil.copytree('kitty', os.path.join(libdir, 'kitty'), ignore=src_ignore)
|
shutil.copytree('kitty', os.path.join(libdir, 'kitty'), ignore=src_ignore)
|
||||||
shutil.copytree('kittens', os.path.join(libdir, 'kittens'), ignore=src_ignore)
|
shutil.copytree('kittens', os.path.join(libdir, 'kittens'), ignore=src_ignore)
|
||||||
with open(os.path.join(libdir, 'kitty/config_data.py'), 'r+', encoding='utf-8') as f:
|
if args.update_check_interval != 24.0:
|
||||||
raw = f.read()
|
with open(os.path.join(libdir, 'kitty/config_data.py'), 'r+', encoding='utf-8') as f:
|
||||||
nraw = raw.replace("update_check_interval', 24", "update_check_interval', {}".format(args.update_check_interval), 1)
|
raw = f.read()
|
||||||
if nraw == raw:
|
nraw = raw.replace("update_check_interval', 24", "update_check_interval', {}".format(args.update_check_interval), 1)
|
||||||
raise SystemExit('Failed to change the value of update_check_interval')
|
if nraw == raw:
|
||||||
f.seek(0), f.truncate(), f.write(nraw)
|
raise SystemExit('Failed to change the value of update_check_interval')
|
||||||
|
f.seek(0), f.truncate(), f.write(nraw)
|
||||||
compile_python(libdir)
|
compile_python(libdir)
|
||||||
for root, dirs, files in os.walk(libdir):
|
for root, dirs, files in os.walk(libdir):
|
||||||
for f in files:
|
for f in files:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user