-
-
Notifications
You must be signed in to change notification settings - Fork 96
Extra files #230
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Extra files #230
Changes from 16 commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
9bd4b29
Support for shipping extra files
simonhamp 92930ba
Add extras path to PHP environment
simonhamp 075308a
Fix path
simonhamp 993ad13
Formatting
simonhamp ea94a73
Merge branch 'main' of https://github.com/NativePHP/electron into fea…
PeteBishwhip 20a5c16
Change path
simonhamp a825ba2
Change path
simonhamp 4f6fb0e
fix `npm install` error during plugin build
gwleuverink 608a454
Merge remote-tracking branch 'origin/main' into feature/extras
gwleuverink 210bcec
specify head ref in auto-commit-action
gwleuverink 183d6bf
revert: specify head ref in auto-commit-action
gwleuverink 35e0459
revert auto-commit-action to v5
gwleuverink 9869cda
Build plugin
gwleuverink 6043353
explicitly pass builder config
gwleuverink f9a0103
Merge branch 'main' into feature/extras
gwleuverink e006bb3
fix paths
gwleuverink df1ed48
Build plugin
gwleuverink e23113e
don't include 'extras' in asar archive
gwleuverink 710ce02
Merge branch 'feature/extras' of github.com:NativePHP/electron into f…
gwleuverink f9c3fe5
use auto-commit v6
gwleuverink File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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 |
---|---|---|
|
@@ -265,6 +265,7 @@ interface EnvironmentVariables { | |
NATIVEPHP_PICTURES_PATH: string; | ||
NATIVEPHP_VIDEOS_PATH: string; | ||
NATIVEPHP_RECENT_PATH: string; | ||
NATIVEPHP_EXTRAS_PATH: string; | ||
// Cache variables | ||
APP_SERVICES_CACHE?: string; | ||
APP_PACKAGES_CACHE?: string; | ||
|
@@ -293,6 +294,9 @@ function getDefaultEnvironmentVariables(secret?: string, apiPort?: number): Envi | |
NATIVEPHP_PICTURES_PATH: getPath('pictures'), | ||
NATIVEPHP_VIDEOS_PATH: getPath('videos'), | ||
NATIVEPHP_RECENT_PATH: getPath('recent'), | ||
NATIVEPHP_EXTRAS_PATH: app.isPackaged | ||
? join(process.resourcesPath, '..', 'extras') | ||
: join(process.env.APP_PATH, 'extras'), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I installed the electron package from a symlinked directory. Using |
||
}; | ||
|
||
// Only if the server has already started | ||
|
This file contains hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The original
join(app.getAppPath(), 'nativephp', 'extras')
pointed to
playground.app/Contents/Resources/app.asar/nativephp/extras
Electron builder automatically the extra files in
playground.app/Contents/extras
.Using
process.resourcesPath
instead points it to the right place