Skip to content

Commit

Permalink
fix: migrate git sync to using bun based script
Browse files Browse the repository at this point in the history
  • Loading branch information
rubenfiszel committed Sep 9, 2024
1 parent 5e822c8 commit 6b43d7e
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 7 deletions.
5 changes: 3 additions & 2 deletions frontend/src/lib/hubPaths.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"gitSync": "hub/8931/sync-script-to-git-repo-windmill",
"gitSyncTest": "hub/8944/git-repo-test-read-write-windmill",
"gitSyncLegacy0": "hub/8931/sync-script-to-git-repo-windmill",
"gitSync": "hub/9074/sync-script-to-git-repo-windmill",
"gitSyncTest": "hub/9073/git-repo-test-read-write-windmill",
"slackErrorHandler": "hub/6512/workspace-or-schedule-error-handler-slack",
"slackRecoveryHandler": "hub/9067/slack/schedule-recovery-handler-slack",
"slackRecoveryHandler_0": "hub/2430/slack/schedule-recovery-handler-slack",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,13 @@
type Script,
type WorkspaceDeployUISettings
} from '$lib/gen'
import { defaultIfEmptyString, emptyString, canWrite, truncateHash } from '$lib/utils'
import {
defaultIfEmptyString,
emptyString,
canWrite,
truncateHash,
copyToClipboard
} from '$lib/utils'
import Tooltip from '$lib/components/Tooltip.svelte'
import ShareModal from '$lib/components/ShareModal.svelte'
import { enterpriseLicense, hubBaseUrlStore, userStore, workspaceStore } from '$lib/stores'
Expand Down Expand Up @@ -56,7 +62,8 @@
Share,
Table2,
Trash,
Play
Play,
ClipboardCopy
} from 'lucide-svelte'
import { SCRIPT_VIEW_SHOW_PUBLISH_TO_HUB } from '$lib/consts'
import { scriptToHubUrl } from '$lib/hub'
Expand Down Expand Up @@ -738,9 +745,21 @@
<TabContent value="dependencies">
<div>
{#if script?.lock}
<pre class="bg-surface-secondary text-sm p-2 h-full overflow-auto w-full"
>{script.lock}</pre
>
<div class="relative overflow-x-auto w-full">
<Button
wrapperClasses="absolute top-2 right-2 z-20"
on:click={() => copyToClipboard(script.lock)}
color="light"
size="xs2"
startIcon={{
icon: ClipboardCopy
}}
iconOnly
/>
<pre class="bg-surface-secondary text-sm p-2 h-full overflow-auto w-full"
>{script.lock}</pre
>
</div>
{:else}
<p class="bg-surface-secondary text-sm p-2">
There is no lock file for this script
Expand Down

0 comments on commit 6b43d7e

Please sign in to comment.