Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(ceremony): change and move command #3097

Merged
merged 1 commit into from
Oct 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions ceremony/src/lib/components/Terminal/Install/Linux.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { sleep } from "$lib/utils/utils.ts"
import Buttons from "$lib/components/Terminal/Install/Buttons.svelte"
import { axiom } from "$lib/utils/axiom.ts"
import { user } from "$lib/state/session.svelte.ts"
import { COMMAND } from "$lib/constants"

type Props = {
change: () => void
Expand All @@ -15,9 +16,6 @@ let { change }: Props = $props()

let showButtons = $state(true)

let command =
"mkdir -p ceremony && docker pull ghcr.io/unionlabs/union/mpc-client:multi && docker run -v $(pwd)/ceremony:/ceremony -w /ceremony -p 4919:4919 --rm -it ghcr.io/unionlabs/union/mpc-client:multi"

onMount(() => {
terminal.setStep(3)
axiom.ingest("monitor", [{ user: user.session?.user.id, type: "mount_linux" }])
Expand All @@ -26,7 +24,7 @@ onMount(() => {
text: "You must have docker installed and running in order to contribute. Once you have docker running, copy the following command in your terminal:"
},
{ text: "---", duplicate: true },
{ text: command, duplicate: true },
{ text: COMMAND, duplicate: true },
{ text: "---", duplicate: true },
{ text: "Once the MPC client is running you can return to this page.", duplicate: true },
{ text: "---", duplicate: true },
Expand All @@ -46,7 +44,7 @@ const copy = async () => {
showButtons = false
terminal.updateHistory({ text: "Copying command...", duplicate: true })
await sleep(500)
await navigator.clipboard.writeText(command)
await navigator.clipboard.writeText(COMMAND)
terminal.updateHistory({ text: "Command copied!", duplicate: true })
await sleep(500)
showButtons = true
Expand Down
8 changes: 3 additions & 5 deletions ceremony/src/lib/components/Terminal/Install/MacOS.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { sleep } from "$lib/utils/utils.ts"
import Buttons from "$lib/components/Terminal/Install/Buttons.svelte"
import { axiom } from "$lib/utils/axiom.ts"
import { user } from "$lib/state/session.svelte.ts"
import { COMMAND } from "$lib/constants"

type Props = {
change: () => void
Expand All @@ -15,9 +16,6 @@ let { change }: Props = $props()

let showButtons = $state(true)

let command =
"mkdir -p ceremony && docker pull ghcr.io/unionlabs/union/mpc-client:v1.0 && docker run -v $(pwd)/ceremony:/ceremony -w /ceremony -p 4919:4919 --rm -it ghcr.io/unionlabs/union/mpc-client:v1.0"

onMount(() => {
terminal.setStep(3)
axiom.ingest("monitor", [{ user: user.session?.user.id, type: "mount_macos" }])
Expand All @@ -38,7 +36,7 @@ onMount(() => {
text: "5. Paste the following command in Terminal to start the MPC client:"
},
{ text: "---", duplicate: true },
{ text: command },
{ text: COMMAND },
{ text: "---", duplicate: true },
{
text: "Once the MPC client is running you can return to this page."
Expand All @@ -59,7 +57,7 @@ const copy = async () => {
showButtons = false
terminal.updateHistory({ text: "Copying command...", duplicate: true })
await sleep(500)
await navigator.clipboard.writeText(command)
await navigator.clipboard.writeText(COMMAND)
terminal.updateHistory({ text: "Command copied!", duplicate: true })
await sleep(500)
showButtons = true
Expand Down
2 changes: 2 additions & 0 deletions ceremony/src/lib/constants/index.ts
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
export const AXIOM_KEY = "xaat-c2ba1f52-0af4-4814-81d1-996c285912c8"
export const COMMAND =
"mkdir -p ceremony && docker pull ghcr.io/unionlabs/union/mpc-client:v1.1 && docker run -v $(pwd)/ceremony:/ceremony -w /ceremony -p 4919:4919 --rm -it ghcr.io/unionlabs/union/mpc-client:v1.1"