update new compile so it doesent force updates
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
local service={}
|
local service={}
|
||||||
local fs=require("fs")
|
local fs=require("fs")
|
||||||
local reactor=syscall.open("/dev/raw/by-type/fissionReactorLogicAdapter/1","rw")
|
local reactor=syscall.open("/dev/raw/by-type/fissionReactorLogicAdapter/1","rw")
|
||||||
local boiler=syscall.open("/dev/raw/by-type/boilerValve/1")
|
local boiler=syscall.open("/dev/raw/by-type/boilerValve/1","rw")
|
||||||
local exit=false
|
local exit=false
|
||||||
local temp,fuel,waste,hcool,cool,dmg = 0,0,0,0,0,0
|
local temp,fuel,waste,hcool,cool,dmg = 0,0,0,0,0,0
|
||||||
function service.dmgservice()
|
function service.dmgservice()
|
||||||
@@ -12,24 +12,33 @@ end
|
|||||||
|
|
||||||
function service.wasteservice()
|
function service.wasteservice()
|
||||||
while not exit do
|
while not exit do
|
||||||
|
waste=syscall.devctl(reactor, "getWastePercent")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function service.coolantservice()
|
function service.coolantservice()
|
||||||
while not exit do
|
while not exit do
|
||||||
|
hcool=syscall.devctl(reactor, "getHeatedCoolantPercent")
|
||||||
|
cool=syscall.devctl(reactor, "getHeatedCoolantPercent")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function service.extraservice()
|
function service.extraservice()
|
||||||
while not exit do
|
while not exit do
|
||||||
|
syscall.exit()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function service.storeservice()
|
function service.storeservice()
|
||||||
while not exit do
|
while not exit do
|
||||||
|
syscall.exit()
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
for name, func in pairs(service) do
|
||||||
|
syscall.spawn(func, name)
|
||||||
|
end
|
||||||
|
|
||||||
|
while true do
|
||||||
|
print(temp,fuel,hcool,cool,dmg,waste)
|
||||||
end
|
end
|
||||||
+31
-5
@@ -2,8 +2,8 @@
|
|||||||
|
|
||||||
import hashlib
|
import hashlib
|
||||||
import json
|
import json
|
||||||
import shutil
|
import shutil, io
|
||||||
import tarfile
|
import tarfile, gzip
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
ROOT = Path(__file__).resolve().parent
|
ROOT = Path(__file__).resolve().parent
|
||||||
@@ -14,7 +14,7 @@ PACKAGE_DIR = PACKAGE_ROOT / "raw"
|
|||||||
# main repo
|
# main repo
|
||||||
API_ROOT = "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main"
|
API_ROOT = "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main"
|
||||||
|
|
||||||
#local repo
|
# local repo
|
||||||
#API_ROOT = "http://localhost:8001"
|
#API_ROOT = "http://localhost:8001"
|
||||||
|
|
||||||
DEFAULT_VERSION = "0.0.0"
|
DEFAULT_VERSION = "0.0.0"
|
||||||
@@ -89,6 +89,15 @@ def read_dependencies(folder):
|
|||||||
|
|
||||||
return dependencies if dependencies else DEFAULT_DEPENDENCIES
|
return dependencies if dependencies else DEFAULT_DEPENDENCIES
|
||||||
|
|
||||||
|
def reproducible_filter(info):
|
||||||
|
info.mtime = 0
|
||||||
|
info.uid = 0
|
||||||
|
info.gid = 0
|
||||||
|
info.uname = ""
|
||||||
|
info.gname = ""
|
||||||
|
|
||||||
|
return info
|
||||||
|
|
||||||
|
|
||||||
def create_package(folder):
|
def create_package(folder):
|
||||||
name = folder.name
|
name = folder.name
|
||||||
@@ -102,8 +111,25 @@ def create_package(folder):
|
|||||||
|
|
||||||
debug(f"Packing {name}")
|
debug(f"Packing {name}")
|
||||||
|
|
||||||
with tarfile.open(tarball, "w:gz") as archive:
|
# Create deterministic TAR
|
||||||
archive.add(folder, arcname=name, filter=exclude)
|
tar_data = io.BytesIO()
|
||||||
|
|
||||||
|
with tarfile.open(fileobj=tar_data, mode="w") as archive:
|
||||||
|
archive.add(
|
||||||
|
folder,
|
||||||
|
arcname=name,
|
||||||
|
filter=reproducible_filter,
|
||||||
|
)
|
||||||
|
|
||||||
|
# Create deterministic gzip
|
||||||
|
compressed = gzip.compress(
|
||||||
|
tar_data.getvalue(),
|
||||||
|
compresslevel=9,
|
||||||
|
mtime=0,
|
||||||
|
)
|
||||||
|
|
||||||
|
with open(tarball, "wb") as file:
|
||||||
|
file.write(compressed)
|
||||||
|
|
||||||
package_hash = sha256(tarball)
|
package_hash = sha256(tarball)
|
||||||
|
|
||||||
|
|||||||
@@ -4,6 +4,6 @@
|
|||||||
"authors": [],
|
"authors": [],
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"hash": "b9949aaa204f24d69b74c38efc42af8b",
|
"hash": "e79cdd6587271fe3e8966df984a30ddf",
|
||||||
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/Hypersplash.tar.gz"
|
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/Hypersplash.tar.gz"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,6 +7,6 @@
|
|||||||
],
|
],
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"hash": "b5b39d1f3fb742274b9cf97333cb7535",
|
"hash": "bed11e2cab125cfa58e5bbf3afc51242",
|
||||||
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/brainfuck.tar.gz"
|
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/brainfuck.tar.gz"
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -4,6 +4,6 @@
|
|||||||
"authors": [],
|
"authors": [],
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"hash": "422adc2dd07d99cbf1d7ca66383a62a4",
|
"hash": "f0f7d79c21afaab4bd3260db908f82f7",
|
||||||
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/ccemu.tar.gz"
|
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/ccemu.tar.gz"
|
||||||
}
|
}
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -4,6 +4,6 @@
|
|||||||
"authors": [],
|
"authors": [],
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"hash": "a562bab00d47503234da7fee596208b0",
|
"hash": "e52983a4fc1de987784cc2699f570a35",
|
||||||
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/rawexplorer.tar.gz"
|
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/rawexplorer.tar.gz"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,6 +4,6 @@
|
|||||||
"authors": [],
|
"authors": [],
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"hash": "b5cd95451af1948cbe72a193426e66bf",
|
"hash": "69d5178fff65d1dda6e8d3b9e3c14489",
|
||||||
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/reactornoboom.tar.gz"
|
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/reactornoboom.tar.gz"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,6 +4,6 @@
|
|||||||
"authors": [],
|
"authors": [],
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"hash": "a34478ef284cd38bb21e40a1b31c0454",
|
"hash": "b4e3d3e27a6bee3ed9666cbf1a668d4f",
|
||||||
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/rootkit.tar.gz"
|
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/rootkit.tar.gz"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,6 +4,6 @@
|
|||||||
"authors": [],
|
"authors": [],
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"hash": "a5216495d9b4615706627d68251ebec4",
|
"hash": "532314bcebfb951b5480d2f3e185be8f",
|
||||||
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/taskunmanager.tar.gz"
|
"tarball": "https://git.astronand.dev/Astronand/HyperionOS-packages/raw/branch/main/packages/raw/taskunmanager.tar.gz"
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user