~ knotless Search/
↑↓ move↵ open⇧↵ all results

johnandersen777.bsky.social/knotless

git that lives in your Atmosphere account

Forked from chadtmiller.com/knotless

0
0
30 lines · 1012 B Raw History
<script lang="ts">
	import { LOGIN } from '#lib/login.ts';
	import Meta from '#lib/atoms/Meta.svelte';
	import NewRepoForm from '#lib/organisms/NewRepoForm.svelte';
	let { data } = $props();
	const me = $derived(data.viewer?.actor);
</script>

<Meta title="New repository" about="Create a git repository in your Atmosphere account." />

<div class="new-repo">
	<div class="section"><h1>Create a new repository</h1></div>
	{#if me}
		<p class="feed-note">
			A repository holds a project's files and their history, as records in your Atmosphere account.
			Already have one? <a href="/start">Push it</a> to a new name instead.
		</p>
		<NewRepoForm owner={me.handle} spaces={data.viewer?.spaces} />
	{:else if data.viewer?.login}
		<p class="feed-note">
			Log in to create a repository in your account. <button class="btn" popovertarget={LOGIN}
				>Log in</button
			>
		</p>
	{:else}
		<p class="feed-note">
			This server has no logins: create one with <code>knotless repo create</code>.
		</p>
	{/if}
</div>