Skip to content

Commit

Permalink
Remove version checking
Browse files Browse the repository at this point in the history
  • Loading branch information
hgw8 committed Dec 10, 2023
1 parent 4c87370 commit 7dc5671
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 46 deletions.
33 changes: 1 addition & 32 deletions client/components/VersionChecker.vue
Original file line number Diff line number Diff line change
@@ -1,37 +1,6 @@
<template>
<div id="version-checker" :class="[store.state.versionStatus]">
<p v-if="store.state.versionStatus === 'loading'">Checking for updates…</p>
<p v-if="store.state.versionStatus === 'new-version'">
Hard Lounge <b>{{ store.state.versionData?.latest.version }}</b>
<template v-if="store.state.versionData?.latest.prerelease"> (pre-release) </template>
is now available.
<br />

<a :href="store.state.versionData?.latest.url" target="_blank" rel="noopener">
Read more on GitHub
</a>
</p>
<p v-if="store.state.versionStatus === 'new-packages'">
Hard Lounge is up to date, but there are out of date packages Run
<code>thelounge upgrade</code> on the server to upgrade packages.
</p>
<template v-if="store.state.versionStatus === 'up-to-date'">
<p>Hard Lounge is up to date!</p>

<button
v-if="store.state.versionDataExpired"
id="check-now"
class="btn btn-small"
@click="checkNow"
>
Check now
</button>
</template>
<template v-if="store.state.versionStatus === 'error'">
<p>Information about latest release could not be retrieved.</p>

<button id="check-now" class="btn btn-small" @click="checkNow">Try again</button>
</template>
<p>Check for updates yourself you lazy bum</p>
</div>
</template>

Expand Down
14 changes: 4 additions & 10 deletions client/components/Windows/Help.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,17 @@
v{{
store.state.serverConfiguration?.version
}}
(<router-link id="view-changelog" to="/changelog"
>release notes</router-link
>)
</small>
</h2>

<div class="about">
<VersionChecker />
<p>
<a
href="https://git.supernets.org/supernets/hardlounge/"
target="_blank"
rel="noopener"
class="website-link"
>Website</a
>Source Code</a
>
</p>
<p>
Expand All @@ -35,7 +31,7 @@
target="_blank"
rel="noopener"
class="documentation-link"
>Documentation</a
>Documentation (The Lounge)</a
>
</p>
<p>
Expand Down Expand Up @@ -1228,14 +1224,12 @@
import { defineComponent, ref } from "vue";
import { useStore } from "../../js/store";
import SidebarToggle from "../SidebarToggle.vue";
import VersionChecker from "../VersionChecker.vue";
export default defineComponent({
name: "Help",
components: {
SidebarToggle,
VersionChecker,
},
SidebarToggle
},
setup() {
const store = useStore();
const isApple =
Expand Down
1 change: 0 additions & 1 deletion server/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,6 @@ export default async function (
});
}

changelog.checkForUpdates(manager);
});

return server;
Expand Down
3 changes: 0 additions & 3 deletions test/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ describe("Server", function () {
let server;
let logInfoStub: sinon.SinonStub<string[], void>;
let logWarnStub: sinon.SinonStub<string[], void>;
let checkForUpdatesStub: sinon.SinonStub<[manager: ClientManager], void>;

before(async function () {
logInfoStub = sinon.stub(log, "info");
Expand All @@ -34,7 +33,6 @@ describe("Server", function () {
console.error(`Unhandled log.warn in server tests: ${args.join(" ")}`);
});

checkForUpdatesStub = sinon.stub(changelog, "checkForUpdates");
server = await (await import("../server/server")).default({} as any);
});

Expand All @@ -43,7 +41,6 @@ describe("Server", function () {
// in case setup crashed for any reason
logInfoStub.restore();
logWarnStub.restore();
checkForUpdatesStub.restore();
server.close(done);
});

Expand Down

0 comments on commit 7dc5671

Please sign in to comment.