Skip to content

Commit

Permalink
Merge pull request #26 from GalaxyPay/dev
Browse files Browse the repository at this point in the history
chore: release v.2.0.2
  • Loading branch information
acfunk authored Dec 7, 2024
2 parents 8fc4993 + 5fce526 commit 82938b9
Show file tree
Hide file tree
Showing 9 changed files with 21 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,5 +139,5 @@ jobs:
uses: ncipollo/release-action@v1
with:
allowUpdates: true
tag: v2.0.1
tag: v2.0.2
artifacts: "Output/*"
2 changes: 1 addition & 1 deletion FUNC.iss
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

#define MyAppName "FUNC"
#define MyAppVersion "2.0.1"
#define MyAppVersion "2.0.2"
#define MyAppPublisher "Galaxy Pay, LLC"
#define MyAppPublisherURL "https://galaxy-pay.com"
#define MyPublishPath "publish"
Expand Down
7 changes: 4 additions & 3 deletions FUNC/Controllers/GoalController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ public async Task<ActionResult<string>> GoalUpdate(Models.Release model)
release = await client.Repository.Release.Get(workspaceName, repositoryName, model.Name);
}
url = release?.Assets.FirstOrDefault(a => a.Name == "node.tar.gz")?.BrowserDownloadUrl;
if (url == null) return BadRequest();
await Utils.ExecCmd($"curl -L -o {Utils.dataPath}/node.tar.gz {url}");
}
else if (IsLinux())
{
Expand All @@ -91,11 +93,10 @@ public async Task<ActionResult<string>> GoalUpdate(Models.Release model)
var latestInfo = await client.Repository.Release.GetLatest(workspaceName, repositoryName);
url = latestInfo.Assets.FirstOrDefault(a => a.Name.Contains("node_stable_linux-amd64")
&& a.Name.EndsWith("tar.gz"))?.BrowserDownloadUrl;
if (url == null) return BadRequest();
await Utils.ExecCmd($"wget -L -o {Utils.dataPath}/node.tar.gz {url}");
}

if (url == null) return BadRequest();

await Utils.ExecCmd($"curl -L -o {Utils.dataPath}/node.tar.gz {url}");
await Utils.ExecCmd($"tar -zxf {Utils.dataPath}/node.tar.gz -C {Utils.dataPath} bin");
await Utils.ExecCmd($"rm {Utils.dataPath}/node.tar.gz");

Expand Down
4 changes: 2 additions & 2 deletions FUNC/Controllers/RetiController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public async Task<ActionResult> CreateRetiService(RetiCreate model)
{
var url = latest.Assets.FirstOrDefault(a => a.Name.Contains("linux-amd64.tar.gz"))?.BrowserDownloadUrl;
if (url == null) return BadRequest();
await Utils.ExecCmd($"curl -L -o {Utils.dataPath}/reti.tar.gz {url}");
await Utils.ExecCmd($"wget -L -o {Utils.dataPath}/reti.tar.gz {url}");
await Utils.ExecCmd($"tar -zxf {Utils.dataPath}/reti.tar.gz -C {Path.Combine(Utils.dataPath, "reti")}");
}
}
Expand Down Expand Up @@ -108,7 +108,7 @@ public async Task<ActionResult> UpdateReti()
{
var url = latest.Assets.FirstOrDefault(a => a.Name.Contains("linux-amd64.tar.gz"))?.BrowserDownloadUrl;
if (url == null) return BadRequest();
await Utils.ExecCmd($"curl -L -o {Utils.dataPath}/reti.tar.gz {url}");
await Utils.ExecCmd($"wget -L -o {Utils.dataPath}/reti.tar.gz {url}");
await Utils.ExecCmd($"tar -zxf {Utils.dataPath}/reti.tar.gz -C {Utils.dataPath} reti");
}

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ When updating a previous installation, the installer will recommend to let it au
After downloading the `.deb` file to your machine, run

```sh
sudo dpkg -i linux_func_<version>.deb
sudo dpkg -i func_<version>_amd64.deb
```

Then visit the locally hosted webpage at <http://localhost:3536> (for remote access see notes below)
Expand Down
2 changes: 1 addition & 1 deletion create-package.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
rm -r Output

PKG=Output/func_2.0.1_amd64
PKG=Output/func_2.0.2_amd64

mkdir -p $PKG/lib/systemd/system
mkdir -p $PKG/opt/func
Expand Down
2 changes: 1 addition & 1 deletion deb/control
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Package: func
Version: 2.0.1
Version: 2.0.2
Section: base
Priority: optional
Architecture: amd64
Expand Down
2 changes: 1 addition & 1 deletion webui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "func-webui",
"version": "2.0.1",
"version": "2.0.2",
"scripts": {
"dev": "vite",
"build": "vue-tsc --noEmit && vite build",
Expand Down
10 changes: 9 additions & 1 deletion webui/src/components/Settings.vue
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ const show = computed({
});
const goalVersion = ref<GoalVersion>();
let init = false;
onBeforeMount(() => {
getVersion();
Expand All @@ -84,7 +85,14 @@ async function getVersion() {
const version = await FUNC.api.get("goal/version");
goalVersion.value = version.data;
if (goalVersion.value?.installed) store.ready = true;
else updateLatest(true);
else {
if (!init) {
init = true;
updateLatest(true);
} else {
throw Error("Download Failed");
}
}
store.updateAvailable =
goalVersion.value?.latest !== goalVersion.value?.installed;
Expand Down

0 comments on commit 82938b9

Please sign in to comment.