diff --git a/.github/workflows/autowiki.yml b/.github/workflows/autowiki.yml index 0a431d520ba..91ab12cdb19 100644 --- a/.github/workflows/autowiki.yml +++ b/.github/workflows/autowiki.yml @@ -30,9 +30,6 @@ jobs: - name: Install rust-g if: steps.secrets_set.outputs.SECRETS_ENABLED run: | - sudo dpkg --add-architecture i386 - sudo apt update || true - sudo apt install -o APT::Immediate-Configure=false libssl1.1:i386 bash tools/ci/install_rust_g.sh - name: Compile and generate Autowiki files if: steps.secrets_set.outputs.SECRETS_ENABLED diff --git a/.github/workflows/run_integration_tests.yml b/.github/workflows/run_integration_tests.yml index 0c4ba61a8a4..404119d9880 100644 --- a/.github/workflows/run_integration_tests.yml +++ b/.github/workflows/run_integration_tests.yml @@ -18,7 +18,7 @@ on: type: string jobs: run_integration_tests: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest services: mysql: image: mysql:latest @@ -43,9 +43,6 @@ jobs: mysql -u root -proot tg_ci_prefixed < SQL/tgstation_schema_prefixed.sql - name: Install rust-g run: | - sudo dpkg --add-architecture i386 - sudo apt update || true - sudo apt install -o APT::Immediate-Configure=false libssl1.1:i386 bash tools/ci/install_rust_g.sh - name: Install auxlua run: | diff --git a/code/__DEFINES/rust_g.dm b/code/__DEFINES/rust_g.dm index cab4430a88d..76e5fa22d47 100644 --- a/code/__DEFINES/rust_g.dm +++ b/code/__DEFINES/rust_g.dm @@ -110,6 +110,12 @@ #define rustg_dmi_strip_metadata(fname) RUSTG_CALL(RUST_G, "dmi_strip_metadata")(fname) #define rustg_dmi_create_png(path, width, height, data) RUSTG_CALL(RUST_G, "dmi_create_png")(path, width, height, data) #define rustg_dmi_resize_png(path, width, height, resizetype) RUSTG_CALL(RUST_G, "dmi_resize_png")(path, width, height, resizetype) +/** + * input: must be a path, not an /icon; you have to do your own handling if it is one, as icon objects can't be directly passed to rustg. + * + * output: json_encode'd list. json_decode to get a flat list with icon states in the order they're in inside the .dmi + */ +#define rustg_dmi_icon_states(fname) RUSTG_CALL(RUST_G, "dmi_icon_states")(fname) #define rustg_file_read(fname) RUSTG_CALL(RUST_G, "file_read")(fname) #define rustg_file_exists(fname) RUSTG_CALL(RUST_G, "file_exists")(fname) @@ -158,8 +164,9 @@ #define rustg_time_milliseconds(id) text2num(RUSTG_CALL(RUST_G, "time_milliseconds")(id)) #define rustg_time_reset(id) RUSTG_CALL(RUST_G, "time_reset")(id) +/// Returns the timestamp as a string /proc/rustg_unix_timestamp() - return text2num(RUSTG_CALL(RUST_G, "unix_timestamp")()) + return RUSTG_CALL(RUST_G, "unix_timestamp")() #define rustg_raw_read_toml_file(path) json_decode(RUSTG_CALL(RUST_G, "toml_file_to_json")(path) || "null") diff --git a/code/datums/helper_datums/getrev.dm b/code/datums/helper_datums/getrev.dm index 06e2c1e18d6..c3562aa5987 100644 --- a/code/datums/helper_datums/getrev.dm +++ b/code/datums/helper_datums/getrev.dm @@ -37,6 +37,8 @@ else if(!originmastercommit) msg += "No commit information" + msg += "Running rust-g version [rustg_get_version()]" + return msg.Join("\n") /datum/getrev/proc/GetTestMergeInfo(header = TRUE) diff --git a/dependencies.sh b/dependencies.sh index b24b85d55b2..6162b349b51 100644 --- a/dependencies.sh +++ b/dependencies.sh @@ -8,7 +8,7 @@ export BYOND_MAJOR=514 export BYOND_MINOR=1588 #rust_g git tag -export RUST_G_VERSION=1.2.0 +export RUST_G_VERSION=3.0.0 #node version export NODE_VERSION=14 diff --git a/tools/tgs_scripts/PreCompile.sh b/tools/tgs_scripts/PreCompile.sh index 499073d9032..9f2f94646ed 100755 --- a/tools/tgs_scripts/PreCompile.sh +++ b/tools/tgs_scripts/PreCompile.sh @@ -12,6 +12,7 @@ cd "$1" . dependencies.sh cd "$original_dir" + # update rust-g if [ ! -d "rust-g" ]; then echo "Cloning rust-g..."