mirror of
https://github.com/hzrd149/nostrudel.git
synced 2025-09-25 19:23:45 +02:00
update docker job
This commit is contained in:
14
.github/workflows/docker-image.yml
vendored
14
.github/workflows/docker-image.yml
vendored
@@ -1,9 +1,7 @@
|
|||||||
name: Create and publish a Docker image
|
name: Create and publish a Docker image
|
||||||
# copied from https://blog.pradumnasaraf.dev/publish-image-on-ghcr
|
# copied from https://blog.pradumnasaraf.dev/publish-image-on-ghcr
|
||||||
|
|
||||||
on:
|
on: push
|
||||||
push:
|
|
||||||
branches: ["master"]
|
|
||||||
|
|
||||||
env:
|
env:
|
||||||
REGISTRY: ghcr.io
|
REGISTRY: ghcr.io
|
||||||
@@ -32,10 +30,18 @@ jobs:
|
|||||||
uses: docker/metadata-action@v4
|
uses: docker/metadata-action@v4
|
||||||
with:
|
with:
|
||||||
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
||||||
|
tags: |
|
||||||
|
type=schedule
|
||||||
|
type=semver,pattern={{version}}
|
||||||
|
type=semver,pattern={{major}}.{{minor}}
|
||||||
|
type=semver,pattern={{major}}
|
||||||
|
type=ref,event=branch
|
||||||
|
type=ref,event=pr
|
||||||
|
type=sha
|
||||||
- name: Build and push Docker image
|
- name: Build and push Docker image
|
||||||
uses: docker/build-push-action@v4
|
uses: docker/build-push-action@v4
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
push: true
|
push: true
|
||||||
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
|
33
.github/workflows/release.yml
vendored
Normal file
33
.github/workflows/release.yml
vendored
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
name: Release
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
env:
|
||||||
|
REGISTRY: ghcr.io
|
||||||
|
IMAGE_NAME: ${{ github.repository }}
|
||||||
|
|
||||||
|
concurrency: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
release:
|
||||||
|
name: Release
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout Repo
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Setup Node.js 18
|
||||||
|
uses: actions/setup-node@v3
|
||||||
|
with:
|
||||||
|
node-version: 18
|
||||||
|
|
||||||
|
- name: Install Dependencies
|
||||||
|
run: yarn
|
||||||
|
|
||||||
|
- name: Create Release Pull Request
|
||||||
|
uses: changesets/action@v1
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
@@ -45,8 +45,6 @@ export default function DesktopSideNav(props: Omit<FlexProps, "children">) {
|
|||||||
</LinkOverlay>
|
</LinkOverlay>
|
||||||
</Heading>
|
</Heading>
|
||||||
</Flex>
|
</Flex>
|
||||||
<NavItems />
|
|
||||||
<Box h="4" />
|
|
||||||
{account && (
|
{account && (
|
||||||
<>
|
<>
|
||||||
<AccountSwitcher />
|
<AccountSwitcher />
|
||||||
@@ -63,6 +61,8 @@ export default function DesktopSideNav(props: Omit<FlexProps, "children">) {
|
|||||||
</Button>
|
</Button>
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
|
<NavItems />
|
||||||
|
<Box h="4" />
|
||||||
{!account && (
|
{!account && (
|
||||||
<Button as={RouterLink} to="/login" state={{ from: location.pathname }} colorScheme="primary" w="full">
|
<Button as={RouterLink} to="/login" state={{ from: location.pathname }} colorScheme="primary" w="full">
|
||||||
Login
|
Login
|
||||||
|
@@ -136,7 +136,7 @@ export const Note = React.memo(
|
|||||||
icon={<ExternalLinkIcon />}
|
icon={<ExternalLinkIcon />}
|
||||||
aria-label="Open External"
|
aria-label="Open External"
|
||||||
href={externalLink}
|
href={externalLink}
|
||||||
size="sm"
|
size="xs"
|
||||||
variant="ghost"
|
variant="ghost"
|
||||||
target="_blank"
|
target="_blank"
|
||||||
/>
|
/>
|
||||||
|
@@ -16,13 +16,14 @@ import { EmbedEvent, EmbedEventPointer } from "../../components/embed-event";
|
|||||||
import EmbeddedUnknown from "../../components/embed-event/event-types/embedded-unknown";
|
import EmbeddedUnknown from "../../components/embed-event/event-types/embedded-unknown";
|
||||||
import { NoteContents } from "../../components/note/note-contents";
|
import { NoteContents } from "../../components/note/note-contents";
|
||||||
import { ErrorBoundary } from "../../components/error-boundary";
|
import { ErrorBoundary } from "../../components/error-boundary";
|
||||||
|
import { TrustProvider } from "../../providers/trust";
|
||||||
|
|
||||||
const Kind1Notification = forwardRef<HTMLDivElement, { event: NostrEvent }>(({ event }, ref) => {
|
const Kind1Notification = forwardRef<HTMLDivElement, { event: NostrEvent }>(({ event }, ref) => {
|
||||||
const refs = getReferences(event);
|
const refs = getReferences(event);
|
||||||
|
|
||||||
if (refs.replyId) {
|
if (refs.replyId) {
|
||||||
return (
|
return (
|
||||||
<Card variant="outline" p="2" borderColor="blue.400" ref={ref}>
|
<Card variant="outline" p="2" ref={ref}>
|
||||||
<Flex gap="2" alignItems="center" mb="2" wrap="wrap">
|
<Flex gap="2" alignItems="center" mb="2" wrap="wrap">
|
||||||
<UserAvatar pubkey={event.pubkey} size="xs" />
|
<UserAvatar pubkey={event.pubkey} size="xs" />
|
||||||
<UserLink pubkey={event.pubkey} />
|
<UserLink pubkey={event.pubkey} />
|
||||||
@@ -118,7 +119,7 @@ const ZapNotification = forwardRef<HTMLDivElement, { event: NostrEvent }>(({ eve
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Card variant="outline" borderColor="yellow.400" p="2" ref={ref}>
|
<Card variant="outline" p="2" ref={ref}>
|
||||||
<Flex direction="row" gap="2" alignItems="center" mb="2">
|
<Flex direction="row" gap="2" alignItems="center" mb="2">
|
||||||
<UserAvatar pubkey={zap.request.pubkey} size="xs" />
|
<UserAvatar pubkey={zap.request.pubkey} size="xs" />
|
||||||
<UserLink pubkey={zap.request.pubkey} />
|
<UserLink pubkey={zap.request.pubkey} />
|
||||||
@@ -152,7 +153,13 @@ const NotificationItem = ({ event }: { event: NostrEvent }) => {
|
|||||||
content = <EmbeddedUnknown event={event} />;
|
content = <EmbeddedUnknown event={event} />;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
return content && <ErrorBoundary>{content}</ErrorBoundary>;
|
return (
|
||||||
|
content && (
|
||||||
|
<ErrorBoundary>
|
||||||
|
<TrustProvider event={event}>{content}</TrustProvider>
|
||||||
|
</ErrorBoundary>
|
||||||
|
)
|
||||||
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export default memo(NotificationItem);
|
export default memo(NotificationItem);
|
||||||
|
Reference in New Issue
Block a user