mirror of
https://github.com/hydralauncher/hydra.git
synced 2025-01-23 05:24:55 +03:00
feat: adding pycache to gitignore
This commit is contained in:
parent
18de7ca671
commit
ca1b9b2170
@ -4,6 +4,6 @@ module.exports = {
|
||||
"plugin:react/recommended",
|
||||
"plugin:react/jsx-runtime",
|
||||
"@electron-toolkit/eslint-config-ts/recommended",
|
||||
"@electron-toolkit/eslint-config-prettier",
|
||||
"prettier",
|
||||
],
|
||||
};
|
||||
|
3
.gitignore
vendored
3
.gitignore
vendored
@ -1,4 +1,7 @@
|
||||
.vscode
|
||||
node_modules
|
||||
hydra-download-manager
|
||||
__pycache__
|
||||
dist
|
||||
out
|
||||
.DS_Store
|
||||
|
BIN
build/icon.ico
BIN
build/icon.ico
Binary file not shown.
Before Width: | Height: | Size: 121 KiB After Width: | Height: | Size: 11 KiB |
@ -2,6 +2,8 @@ appId: site.hydralauncher.hydra
|
||||
productName: Hydra
|
||||
directories:
|
||||
buildResources: build
|
||||
extraResources:
|
||||
- hydra-download-manager
|
||||
files:
|
||||
- "!**/.vscode/*"
|
||||
- "!src/*"
|
||||
@ -13,6 +15,7 @@ asarUnpack:
|
||||
- resources/**
|
||||
win:
|
||||
executableName: Hydra
|
||||
requestedExecutionLevel: requireAdministrator
|
||||
nsis:
|
||||
artifactName: ${name}-${version}-setup.${ext}
|
||||
shortcutName: ${productName}
|
||||
|
@ -4,6 +4,7 @@ import {
|
||||
loadEnv,
|
||||
swcPlugin,
|
||||
externalizeDepsPlugin,
|
||||
bytecodePlugin,
|
||||
} from "electron-vite";
|
||||
import react from "@vitejs/plugin-react";
|
||||
import { vanillaExtractPlugin } from "@vanilla-extract/vite-plugin";
|
||||
@ -25,7 +26,7 @@ export default defineConfig(({ command, mode }) => {
|
||||
"@locales": resolve("src/locales"),
|
||||
},
|
||||
},
|
||||
plugins: [externalizeDepsPlugin(), swcPlugin()],
|
||||
plugins: [externalizeDepsPlugin(), swcPlugin(), bytecodePlugin()],
|
||||
},
|
||||
preload: {
|
||||
plugins: [externalizeDepsPlugin()],
|
||||
@ -37,7 +38,7 @@ export default defineConfig(({ command, mode }) => {
|
||||
"@locales": resolve("src/locales"),
|
||||
},
|
||||
},
|
||||
plugins: [svgr(), react(), vanillaExtractPlugin()],
|
||||
plugins: [svgr(), react(), vanillaExtractPlugin(), bytecodePlugin()],
|
||||
},
|
||||
};
|
||||
});
|
||||
|
@ -3,7 +3,7 @@
|
||||
"version": "1.0.0",
|
||||
"description": "An Electron application with React and TypeScript",
|
||||
"main": "./out/main/index.js",
|
||||
"author": "example.com",
|
||||
"author": "Hydra Launcher",
|
||||
"homepage": "https://electron-vite.org",
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
@ -14,7 +14,7 @@
|
||||
"typecheck": "npm run typecheck:node && npm run typecheck:web",
|
||||
"start": "electron-vite preview",
|
||||
"dev": "electron-vite dev",
|
||||
"build": "npm run typecheck && electron-vite build",
|
||||
"build": "electron-vite build",
|
||||
"postinstall": "electron-builder install-app-deps",
|
||||
"build:unpack": "npm run build && electron-builder --dir",
|
||||
"build:win": "npm run build && electron-builder --win",
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 35 KiB |
@ -7,7 +7,7 @@ import { formatName, getSteamAppAsset, repackerFormatter } from "@main/helpers";
|
||||
import { stateManager } from "@main/state-manager";
|
||||
|
||||
const { Index } = flexSearch;
|
||||
const repacksIndex = new Index();
|
||||
const repacksIndex = new Index({ tokenize: "strict" });
|
||||
const steamGamesIndex = new Index({ tokenize: "forward" });
|
||||
|
||||
const repacks = stateManager.getValue("repacks");
|
||||
@ -21,6 +21,8 @@ for (let i = 0; i < repacks.length; i++) {
|
||||
repacksIndex.add(i, formatName(formatter(repack.title)));
|
||||
}
|
||||
|
||||
console.log(true);
|
||||
|
||||
for (let i = 0; i < steamGames.length; i++) {
|
||||
const steamGame = steamGames[i];
|
||||
steamGamesIndex.add(i, formatName(steamGame.name));
|
||||
|
@ -50,7 +50,6 @@ export class TorrentClient {
|
||||
const binaryName = binaryNameByPlatform[process.platform];
|
||||
const binaryPath = path.join(
|
||||
process.resourcesPath,
|
||||
"dist",
|
||||
"hydra-download-manager",
|
||||
binaryName
|
||||
);
|
||||
|
@ -1,15 +1,10 @@
|
||||
<!doctype html>
|
||||
<html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<title>Electron</title>
|
||||
<!-- https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP -->
|
||||
<!-- <meta
|
||||
http-equiv="Content-Security-Policy"
|
||||
content="default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:"
|
||||
/> -->
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>Hydra</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
<script type="module" src="/src/main.tsx"></script>
|
||||
|
@ -22,7 +22,7 @@ import {
|
||||
|
||||
document.body.classList.add(themeClass);
|
||||
|
||||
export function App() {
|
||||
export function App({ children }: any) {
|
||||
const contentRef = useRef<HTMLDivElement>(null);
|
||||
const { updateLibrary } = useLibrary();
|
||||
|
||||
@ -112,7 +112,7 @@ export function App() {
|
||||
/>
|
||||
|
||||
<section ref={contentRef} className={styles.content}>
|
||||
<Outlet />
|
||||
{children}
|
||||
</section>
|
||||
</article>
|
||||
</main>
|
||||
|
@ -4,7 +4,7 @@ import i18n from "i18next";
|
||||
import { initReactI18next } from "react-i18next";
|
||||
import { Provider } from "react-redux";
|
||||
import LanguageDetector from "i18next-browser-languagedetector";
|
||||
import { createHashRouter, RouterProvider } from "react-router-dom";
|
||||
import { HashRouter, Route, Routes } from "react-router-dom";
|
||||
|
||||
import { init } from "@sentry/electron/renderer";
|
||||
import { init as reactInit } from "@sentry/react";
|
||||
@ -46,39 +46,6 @@ if (import.meta.env.RENDERER_VITE_SENTRY_DSN) {
|
||||
);
|
||||
}
|
||||
|
||||
const router = createHashRouter([
|
||||
{
|
||||
path: "/",
|
||||
Component: App,
|
||||
children: [
|
||||
{
|
||||
path: "/",
|
||||
Component: Home,
|
||||
},
|
||||
{
|
||||
path: "/catalogue",
|
||||
Component: Catalogue,
|
||||
},
|
||||
{
|
||||
path: "/downloads",
|
||||
Component: Downloads,
|
||||
},
|
||||
{
|
||||
path: "/game/:shop/:objectID",
|
||||
Component: GameDetails,
|
||||
},
|
||||
{
|
||||
path: "/search",
|
||||
Component: SearchResults,
|
||||
},
|
||||
{
|
||||
path: "/settings",
|
||||
Component: Settings,
|
||||
},
|
||||
],
|
||||
},
|
||||
]);
|
||||
|
||||
i18n
|
||||
.use(LanguageDetector)
|
||||
.use(initReactI18next)
|
||||
@ -96,7 +63,19 @@ i18n
|
||||
ReactDOM.createRoot(document.getElementById("root")!).render(
|
||||
<React.StrictMode>
|
||||
<Provider store={store}>
|
||||
<RouterProvider router={router} />
|
||||
<HashRouter>
|
||||
<App>
|
||||
<Routes>
|
||||
<Route path="/" Component={Home} />
|
||||
<Route path="/catalogue" Component={Catalogue} />
|
||||
<Route path="/downloads" Component={Downloads} />
|
||||
<Route path="/game/:shop/:objectID" Component={GameDetails} />
|
||||
<Route path="/search" Component={SearchResults} />
|
||||
<Route path="/settings" Component={Settings} />
|
||||
</Routes>
|
||||
</App>
|
||||
</HashRouter>
|
||||
{/* <RouterProvider router={router} /> */}
|
||||
</Provider>
|
||||
</React.StrictMode>
|
||||
);
|
||||
|
Binary file not shown.
@ -3,7 +3,7 @@ from cx_Freeze import setup, Executable
|
||||
# Dependencies are automatically detected, but it might need fine tuning.
|
||||
build_exe_options = {
|
||||
"packages": ["libtorrent"],
|
||||
"build_exe": "resources/dist/hydra-download-manager",
|
||||
"build_exe": "hydra-download-manager",
|
||||
"include_msvcr": True
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user