Skip to content

Commit

Permalink
Rename /rust to /backend and /javascript to /client
Browse files Browse the repository at this point in the history
  • Loading branch information
emwalker committed May 24, 2024
1 parent 8a5a70c commit 9d77b08
Show file tree
Hide file tree
Showing 502 changed files with 404 additions and 344 deletions.
34 changes: 17 additions & 17 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,33 +16,33 @@ DBNAME := $(if $(DBNAME),$(DBNAME),digraph_dev)
build: build-container-api build-container-node

build-client:
$(MAKE) -C javascript build
$(MAKE) -C client build

build-container-api:
docker compose build api
docker tag emwalker/digraph-api:latest emwalker/digraph-api:$(shell cat k8s/release)

build-container-node: build-client
docker compose build node
docker compose build client
docker tag emwalker/digraph-node:latest emwalker/digraph-node:$(shell cat k8s/release)

clean:
$(MAKE) -C javascript clean
$(MAKE) -C rust clean
$(MAKE) -C client clean
$(MAKE) -C backend clean

check-javascript: check-rust
$(MAKE) -C javascript check
check-client: check-backend
$(MAKE) -C client check

check-git-clean:
test -z "$(shell git diff-index --name-only HEAD --)"

check-pre-push:
$(MAKE) -C rust check-pre-push
$(MAKE) -C javascript check-pre-push
$(MAKE) -C backend check-pre-push
$(MAKE) -C client check-pre-push
test -z "$(shell git status --porcelain)"

check-rust:
$(MAKE) -C rust check
check-backend:
$(MAKE) -C backend check

deploy-k8s:
kubectl apply -k k8s/overlays/prod
Expand All @@ -60,7 +60,7 @@ logs-prod:
OVERMIND_SOCKET=./.overmind-logs.sock overmind start -f Procfile.logs-prod

migrate:
$(MAKE) -C rust full-migration
$(MAKE) -C backend full-migration

proxy-next:
overmind s -f Procfile.proxies-next
Expand All @@ -81,12 +81,12 @@ reset-db:
bash ./scripts/load-production-db
bash ./scripts/make-fixtures
bash ./scripts/promote-fixtures
$(MAKE) -C rust migrate
$(MAKE) -C backend migrate

reset-data-dir:
rm -rf ~/data/digraph-data
mkdir -p ~/data/digraph-data
$(MAKE) -C rust export
$(MAKE) -C backend export
ls -l ~/data/digraph-data

save-production:
Expand All @@ -101,10 +101,10 @@ start-prod:
start-dev:
overmind start -f Procfile.dev

test-rust:
$(MAKE) -C rust test
test-backend:
$(MAKE) -C backend test

test-js:
$(MAKE) -C javascript test
$(MAKE) -C client test

test: test-js test-rust
test: test-js test-backend
4 changes: 2 additions & 2 deletions Procfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
node: make -C javascript start
frontend: make -C rust start
client: make -C client start
api: make -C backend start
4 changes: 2 additions & 2 deletions Procfile.dev
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
node: make -C javascript start-dev
api: make -C rust start
client: make -C client start-dev
api: make -C backend start
redis: redis-server
4 changes: 2 additions & 2 deletions Procfile.prod
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
node: make -C javascript start
frontend: make -C rust start-prod
client: make -C client start
api: make -C backend start-prod
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { RequestParameters, Variables } from 'relay-runtime';
import { FetcherBase } from '../FetcherBase';
declare type PayloadsType = {
type PayloadsType = {
[key: string]: string;
};
declare class ClientFetcher extends FetcherBase {
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { MouseEventHandler, type ReactNode } from 'react';
import React, { MouseEventHandler, type ReactNode } from 'react';
import { AlertMessageType } from 'components/types';
export declare type OnCloseType = MouseEventHandler<HTMLButtonElement>;
declare type Props = {
export type OnCloseType = MouseEventHandler<HTMLButtonElement>;
type Props = {
children?: ReactNode;
alert: AlertMessageType;
onClose?: OnCloseType;
};
export default function Alert({ children, alert, onClose }: Props): JSX.Element;
export default function Alert({ children, alert, onClose }: Props): React.JSX.Element;
export {};
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
import { Component, ReactElement } from 'react';
import React, { Component, ReactElement } from 'react';
import { AlertMessageType } from 'components/types';
import Alert from './Alert';
declare type Props = {
type Props = {
initialAlertMessages: readonly AlertMessageType[];
};
declare type State = {
type State = {
messages: readonly AlertMessageType[];
alerts: ReactElement<typeof Alert>[];
};
declare class FlashMessages extends Component<Props, State> {
constructor(props: Props);
get alerts(): JSX.Element[];
get alerts(): React.JSX.Element[];
removeAlert: (component: ReactElement<typeof Alert>) => void;
removeMessage: (alert: AlertMessageType) => void;
addMessage: (message: AlertMessageType) => void;
addAlert: (alert: ReactElement<typeof Alert>) => void;
render: () => JSX.Element | null;
render: () => React.JSX.Element | null;
}
export default FlashMessages;
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import { LineItem_item$key } from '__generated__/LineItem_item.graphql';
declare type Props = {
type Props = {
item: LineItem_item$key;
};
export default function LineItem(props: Props): JSX.Element;
export default function LineItem(props: Props): React.JSX.Element;
export {};
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Component, KeyboardEvent } from 'react';
declare type Props = {
import React, { Component, KeyboardEvent } from 'react';
type Props = {
className?: string | undefined;
router: {
push: Function;
Expand All @@ -11,6 +11,6 @@ declare class SearchBox extends Component<Props> {
};
onKeyPress: (event: KeyboardEvent<HTMLInputElement>) => void;
onSearch: (query: string) => void;
render: () => JSX.Element;
render: () => React.JSX.Element;
}
export default SearchBox;
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import React from 'react';
import { Router } from 'found';
import { Homepage_homepage_Query$data as Response } from '__generated__/Homepage_homepage_Query.graphql';
declare type ViewType = Response['view'];
declare type Props = {
type ViewType = Response['view'];
type Props = {
router: Router;
view: ViewType;
};
declare const Homepage: ({ view, router }: Props) => JSX.Element;
declare const Homepage: ({ view, router }: Props) => React.JSX.Element;
export declare const query: import("react-relay").GraphQLTaggedNode;
export default Homepage;
File renamed without changes.
3 changes: 3 additions & 0 deletions client/src/components/Layout/Footer/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import React from 'react';
declare const Footer: () => React.JSX.Element;
export default Footer;
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import React from 'react';
declare const SignIn: () => React.JSX.Element;
export default SignIn;
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import React from 'react';
declare const SignUp: () => React.JSX.Element;
export default SignUp;
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import { UserDropdown_viewer$key } from '__generated__/UserDropdown_viewer.graphql';
declare type Props = {
type Props = {
viewer: UserDropdown_viewer$key;
};
export default function UserDropdown(props: Props): JSX.Element;
export default function UserDropdown(props: Props): React.JSX.Element;
export {};
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import React from 'react';
type Props = {
viewer: any;
};
export default function UserNav(props: Props): React.JSX.Element;
export {};
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
import React from 'react';
import { Router } from 'found';
import { LocationType } from 'components/types';
import { DesktopNav_viewer$key } from '__generated__/DesktopNav_viewer.graphql';
declare type Props = {
type Props = {
location: LocationType;
router: Router;
view: any;
viewer: DesktopNav_viewer$key;
};
export default function DesktopNav(props: Props): JSX.Element;
export default function DesktopNav(props: Props): React.JSX.Element;
export {};
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import React from 'react';
import { Router } from 'found';
import { LocationType } from 'components/types';
declare type Props = {
type Props = {
location: LocationType;
router: Router;
view: any;
viewer: any;
};
declare const _default: ({ location, router, viewer, view }: Props) => JSX.Element;
declare const _default: ({ location, router, viewer, view }: Props) => React.JSX.Element;
export default _default;
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import { SelectedRepo_viewer$key } from '__generated__/SelectedRepo_viewer.graphql';
declare type Props = {
type Props = {
viewer: SelectedRepo_viewer$key;
};
export default function SelectedRepo(props: Props): JSX.Element | null;
export default function SelectedRepo(props: Props): React.JSX.Element | null;
export {};
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
import { ReactNode } from 'react';
import React, { ReactNode } from 'react';
import { Match, Router } from 'found';
import { LayoutQuery$data as Response } from '__generated__/LayoutQuery.graphql';
declare type AlertsType = Response['alerts'];
declare type ViewType = Response['view'];
declare type Props = {
type AlertsType = Response['alerts'];
type ViewType = Response['view'];
type Props = {
alerts: AlertsType;
children?: ReactNode;
router: Router;
match: Match;
view: ViewType;
};
export declare const query: import("react-relay").GraphQLTaggedNode;
export default function Layout({ alerts, children, view, match, router }: Props): JSX.Element;
export default function Layout({ alerts, children, view, match, router }: Props): React.JSX.Element;
export {};
File renamed without changes.
File renamed without changes.
7 changes: 7 additions & 0 deletions client/src/components/LoadingPage/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import React from 'react';
import { LocationType } from 'components/types';
type Props = {
location: LocationType;
};
declare const LoadingPage: ({ location }: Props) => React.JSX.Element;
export default LoadingPage;
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { ReactNode } from 'react';
import React, { ReactNode } from 'react';
import { Props as RelayEnvironmentProviderProps } from 'react-relay/relay-hooks/RelayEnvironmentProvider.react';
interface ProviderProps {
relayEnvironment: RelayEnvironmentProviderProps['environment'];
children?: ReactNode;
}
export declare const Providers: (props: ProviderProps) => JSX.Element;
export declare const Providers: (props: ProviderProps) => React.JSX.Element;
export {};
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { Component, ReactNode } from 'react';
declare type Props = {
import React, { Component, ReactNode } from 'react';
type Props = {
children: ReactNode;
title?: string;
};
declare class Container extends Component<Props> {
get title(): string;
render: () => JSX.Element;
render: () => React.JSX.Element;
}
export default Container;
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import React from 'react';
type Props = {
item: {
createdAt: unknown;
description: string;
};
};
declare const _default: ({ item }: Props) => React.JSX.Element;
export default _default;
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import { LineItems_activity$key } from '__generated__/LineItems_activity.graphql';
declare type Props = {
type Props = {
activity: LineItems_activity$key;
};
export default function LineItems(props: Props): JSX.Element;
export default function LineItems(props: Props): React.JSX.Element;
export {};
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import React from 'react';
import { RecentPage_recent_Query$data as Response } from '__generated__/RecentPage_recent_Query.graphql';
declare type ViewType = Response['view'];
declare type Props = {
type ViewType = Response['view'];
type Props = {
view: ViewType;
};
declare const _default: ({ view }: Props) => JSX.Element;
declare const _default: ({ view }: Props) => React.JSX.Element;
export default _default;
export declare const query: import("react-relay").GraphQLTaggedNode;
File renamed without changes.
7 changes: 7 additions & 0 deletions client/src/components/SignInPage/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import React, { Component } from 'react';
type Props = {};
declare class SignInPage extends Component<Props> {
renderSignInButton: () => React.JSX.Element;
render: () => React.JSX.Element;
}
export default SignInPage;
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import { Component } from 'react';
declare type State = {
import React, { Component } from 'react';
type State = {
gCaptchaResponse: string | null;
};
declare type Props = {};
type Props = {};
declare class SignUpPage extends Component<Props, State> {
constructor(props: Props);
onCaptchaSumit: (token: string | null) => void;
renderCreateAccountButton: () => JSX.Element;
render: () => JSX.Element;
renderCreateAccountButton: () => React.JSX.Element;
render: () => React.JSX.Element;
}
export default SignUpPage;
File renamed without changes.
3 changes: 3 additions & 0 deletions client/src/components/TermsOfUse/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import React from 'react';
declare const _default: () => React.JSX.Element;
export default _default;
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import React from 'react';
import { TopicSearchPage_viewer$key } from '__generated__/TopicSearchPage_viewer.graphql';
import { TopicSearchPage_topic$key } from '__generated__/TopicSearchPage_topic.graphql';
declare type Props = {
type Props = {
topic: TopicSearchPage_topic$key;
viewer: TopicSearchPage_viewer$key;
};
export default function TopicSearchPage(props: Props): JSX.Element;
export default function TopicSearchPage(props: Props): React.JSX.Element;
export {};
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import React from 'react';
import { AddLink_viewer$key } from '__generated__/AddLink_viewer.graphql';
import { AddLink_parentTopic$key } from '__generated__/AddLink_parentTopic.graphql';
declare type Props = {
type Props = {
disabled?: boolean;
parentTopic: AddLink_parentTopic$key;
viewer: AddLink_viewer$key;
};
export default function AddLink(props: Props): JSX.Element;
export default function AddLink(props: Props): React.JSX.Element;
export {};
Loading

0 comments on commit 9d77b08

Please sign in to comment.