-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c9e95c9
commit de2cb8f
Showing
118 changed files
with
23,309 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
dist/ | ||
static/ | ||
.husky/ | ||
node_modules/ | ||
patches/ | ||
stats.html | ||
index.html | ||
.yarn/ | ||
*.scss | ||
src/services/api/schema.ts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
module.exports = { | ||
extends: ['@invoke-ai/eslint-config-react'], | ||
plugins: ['path'], | ||
rules: { | ||
// TODO(psyche): Enable this rule. Requires no default exports in components - many changes. | ||
'react-refresh/only-export-components': 'off', | ||
// TODO(psyche): Enable this rule. Requires a lot of eslint-disable-next-line comments. | ||
'@typescript-eslint/consistent-type-assertions': 'off', | ||
// https://eslint.org/docs/latest/rules/no-promise-executor-return | ||
'no-promise-executor-return': 'error', | ||
// https://github.com/qdanik/eslint-plugin-path | ||
'path/no-relative-imports': ['error', { maxDepth: 0 }], | ||
// https://eslint.org/docs/latest/rules/require-await | ||
'require-await': 'error', | ||
'no-restricted-properties': [ | ||
'error', | ||
{ | ||
object: 'crypto', | ||
property: 'randomUUID', | ||
message: 'Use of crypto.randomUUID is not allowed as it is not available in all browsers.', | ||
}, | ||
], | ||
}, | ||
overrides: [ | ||
// Disallow cross-imports between main and renderer processes | ||
{ | ||
files: ['src/renderer/**/*'], | ||
rules: { | ||
'no-restricted-imports': [ | ||
'error', | ||
{ | ||
paths: [ | ||
{ | ||
name: '@/main', | ||
message: | ||
'Files in @/renderer/* cannot import from @/main/*. If you need to access something from both, consider moving it to @/shared.', | ||
}, | ||
], | ||
patterns: ['@/main/**'], | ||
}, | ||
], | ||
}, | ||
}, | ||
{ | ||
files: ['src/main/**/*'], | ||
rules: { | ||
'no-restricted-imports': [ | ||
'error', | ||
{ | ||
paths: [ | ||
{ | ||
name: '@/renderer', | ||
message: | ||
'Files in @/main/* cannot import from @/renderer/*. If you need to access something from both, consider moving it to @/shared.', | ||
}, | ||
], | ||
patterns: ['@/renderer/**'], | ||
}, | ||
], | ||
}, | ||
}, | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
name: Build Binaries | ||
|
||
on: | ||
push: | ||
release: | ||
types: [released] | ||
workflow_dispatch: | ||
|
||
env: | ||
UV_VERSION: '0.5.11' | ||
|
||
concurrency: | ||
group: ${{ github.event_name }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build-linux: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Download uv | ||
run: | | ||
mkdir bin | ||
curl -L https://github.com/astral-sh/uv/releases/download/${{ env.UV_VERSION }}/uv-x86_64-unknown-linux-gnu.tar.gz -o uv.tar.gz | ||
tar -xzf uv.tar.gz -C ./bin | ||
mv ./bin/uv-x86_64-unknown-linux-gnu/uv ./assets/uv | ||
rm -rf ./bin/uv-x86_64-unknown-linux-gnu | ||
ls -alF ./bin | ||
ls -alF ./assets | ||
- name: setup nodejs | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: '22' | ||
cache: 'npm' | ||
|
||
- name: Install deps and build GUI | ||
run: | | ||
npm install --include=dev | ||
npm run app:dist | ||
- name: Publish artifact - GUI | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: Invoke-Installer-linux-x86_64.AppImage | ||
path: dist/Invoke-Installer-linux-x86_64.AppImage | ||
|
||
build-macos: | ||
runs-on: macos-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Download uv | ||
run: | | ||
mkdir bin | ||
curl -L https://github.com/astral-sh/uv/releases/download/${{ env.UV_VERSION }}/uv-aarch64-apple-darwin.tar.gz -o uv.tar.gz | ||
tar -xzf uv.tar.gz -C ./bin | ||
mv ./bin/uv-aarch64-apple-darwin/uv ./assets/uv | ||
rm -rf ./bin/uv-aarch64-apple-darwin | ||
ls -alF ./bin | ||
ls -alF ./assets | ||
- name: setup nodejs | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: '22' | ||
cache: 'npm' | ||
|
||
- name: Install deps and build GUI | ||
run: | | ||
npm install --include=dev | ||
npm run app:dist | ||
- name: Publish artifact - GUI | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: Invoke-Installer-mac-arm64.dmg | ||
path: dist/Invoke-Installer-mac-arm64.dmg | ||
|
||
build-windows: | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Download uv | ||
run: | | ||
mkdir bin | ||
curl -L https://github.com/astral-sh/uv/releases/download/${{ env.UV_VERSION }}/uv-x86_64-pc-windows-msvc.zip -o uv.zip | ||
unzip uv.zip -d bin/ | ||
mv bin/uv.exe assets/uv.exe | ||
- name: setup nodejs | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: '22' | ||
cache: 'npm' | ||
|
||
- name: Install deps and build GUI | ||
run: | | ||
npm install --include=dev | ||
npm run app:dist | ||
- name: Publish artifact - GUI - UNSIGNED | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: Invoke-Installer-windows-x64-UNSIGNED.exe | ||
path: dist/Invoke-Installer-windows-x64.exe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: Test Electron App | ||
|
||
on: [push, workflow_dispatch] | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Use Node.js 22.x | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 22.x | ||
cache: 'npm' | ||
|
||
- name: Install dependencies | ||
run: npm ci | ||
|
||
- name: Install system dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y xvfb libgbm-dev | ||
- name: Run tests | ||
run: xvfb-run --auto-servernum npm test | ||
|
||
- name: Run code quality checks | ||
run: xvfb-run --auto-servernum npm run lint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
.venv | ||
bin | ||
*.build | ||
*.dist | ||
*.onefile-build | ||
*.bin | ||
__pycache__ | ||
|
||
### Electron ### | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
lerna-debug.log* | ||
|
||
# Diagnostic reports (https://nodejs.org/api/report.html) | ||
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json | ||
|
||
# Runtime data | ||
pids | ||
*.pid | ||
*.seed | ||
*.pid.lock | ||
.DS_Store | ||
|
||
# Directory for instrumented libs generated by jscoverage/JSCover | ||
lib-cov | ||
|
||
# Coverage directory used by tools like istanbul | ||
coverage | ||
*.lcov | ||
|
||
# nyc test coverage | ||
.nyc_output | ||
|
||
# node-waf configuration | ||
.lock-wscript | ||
|
||
# Compiled binary addons (https://nodejs.org/api/addons.html) | ||
build/Release | ||
|
||
# Dependency directories | ||
node_modules/ | ||
jspm_packages/ | ||
|
||
# TypeScript v1 declaration files | ||
typings/ | ||
|
||
# TypeScript cache | ||
*.tsbuildinfo | ||
|
||
# Optional npm cache directory | ||
.npm | ||
|
||
# Optional eslint cache | ||
.eslintcache | ||
|
||
# Optional REPL history | ||
.node_repl_history | ||
|
||
# Output of 'npm pack' | ||
*.tgz | ||
|
||
# Yarn Integrity file | ||
.yarn-integrity | ||
|
||
# dotenv environment variables file | ||
.env | ||
.env.test | ||
|
||
# parcel-bundler cache (https://parceljs.org/) | ||
.cache | ||
|
||
# next.js build output | ||
.next | ||
|
||
# nuxt.js build output | ||
.nuxt | ||
|
||
# vuepress build output | ||
.vuepress/dist | ||
|
||
# Serverless directories | ||
.serverless/ | ||
|
||
# FuseBox cache | ||
.fusebox/ | ||
|
||
# DynamoDB Local files | ||
.dynamodb/ | ||
|
||
# Webpack | ||
.webpack/ | ||
|
||
# Vite | ||
.vite/ | ||
|
||
# Electron-Forge | ||
out/ | ||
|
||
# Electron-builder | ||
dist/ | ||
|
||
# uv executables | ||
uv | ||
uvx | ||
uv.exe | ||
uvx.exe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
v22.12.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
dist/ | ||
public/locales/*.json | ||
!public/locales/en.json | ||
.husky/ | ||
node_modules/ | ||
patches/ | ||
stats.html | ||
index.html | ||
.yarn/ | ||
.yalc/ | ||
*.scss | ||
src/services/api/schema.ts | ||
static/ | ||
src/theme/css/overlayscrollbars.css | ||
src/theme_/css/overlayscrollbars.css | ||
pnpm-lock.yaml | ||
src-installer/**/* | ||
.vscode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
module.exports = { | ||
...require('@invoke-ai/prettier-config-react'), | ||
overrides: [ | ||
{ | ||
files: ['public/locales/*.json'], | ||
options: { | ||
tabWidth: 4, | ||
}, | ||
}, | ||
], | ||
}; |
Oops, something went wrong.