From fb59377d74a7b1732142de0f59500ecf10cac1de Mon Sep 17 00:00:00 2001 From: Joaquim Guimaraes Date: Fri, 18 Jun 2021 01:50:51 +0100 Subject: [PATCH] Added farmr_package.dart/.exe for .deb and .rpm packages --- .github/package.yaml | 2 +- .github/workflows/dart.yml | 3 +++ environment_config.yaml | 2 +- farmr_package.dart | 6 ++++++ 4 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 farmr_package.dart diff --git a/.github/package.yaml b/.github/package.yaml index 8e7c3f33..1bca10c7 100644 --- a/.github/package.yaml +++ b/.github/package.yaml @@ -4,7 +4,7 @@ meta: maintainer: farmr files: "/usr/bin/farmr": - file: farmr + file: farmr_package mode: "0755" user: "root" "/usr/bin/farmr-foxypoolog": diff --git a/.github/workflows/dart.yml b/.github/workflows/dart.yml index 00bd3234..ea63c7d0 100644 --- a/.github/workflows/dart.yml +++ b/.github/workflows/dart.yml @@ -73,6 +73,7 @@ jobs: ./dart-aarch64/dart-sdk/bin/dart pub get ./dart-aarch64/dart-sdk/bin/dart run environment_config:generate ./dart-aarch64/dart-sdk/bin/dart compile exe farmr.dart + ./dart-aarch64/dart-sdk/bin/dart compile exe farmr_package.dart ./farmr.exe harvester onetime - name: Compile x86_64 @@ -81,12 +82,14 @@ jobs: ./dart-x86_64/dart-sdk/bin/dart pub get ./dart-x86_64/dart-sdk/bin/dart run environment_config:generate ./dart-x86_64/dart-sdk/bin/dart compile exe farmr.dart + ./dart-x86_64/dart-sdk/bin/dart compile exe farmr_package.dart ./farmr.exe harvester onetime - name: Renames farmr binary run: | chmod +x ./farmr.exe mv ./farmr.exe ./farmr + mv ./farmr_package.exe ./farmr_package - name: Copying default config.json run: cp config.json config.json.default diff --git a/environment_config.yaml b/environment_config.yaml index b51b991e..8a4e8b5f 100644 --- a/environment_config.yaml +++ b/environment_config.yaml @@ -6,6 +6,6 @@ environment_config: fields: # set of fields for command version: # key name const: true # optional, default to TRUE - default: 1.4.0.4 # optional, default value for key, if not provided key will be required during command run + default: 1.4.0.5dev1 # optional, default value for key, if not provided key will be required during command run dotenv: true # optional, default to FALSE, if this field should be added to .env file \ No newline at end of file diff --git a/farmr_package.dart b/farmr_package.dart new file mode 100644 index 00000000..79bee171 --- /dev/null +++ b/farmr_package.dart @@ -0,0 +1,6 @@ +import 'farmr.dart' as Client; + +//launches farmr client in hpool mode +main(List args) { + Client.main(["package"] + args); +}