-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
airdcpp-extension 2.0.0-beta, ESM updates
- Loading branch information
Showing
14 changed files
with
2,323 additions
and
634 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
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
This file was deleted.
Oops, something went wrong.
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 @@ | ||
import fs from 'fs'; | ||
import path from 'path'; | ||
|
||
import { RemoteExtension } from 'airdcpp-extension'; | ||
|
||
import { fileURLToPath } from 'url'; | ||
|
||
const __filename = fileURLToPath(import.meta.url); | ||
const __dirname = path.dirname(__filename); | ||
|
||
const extensionConfig = { | ||
packageInfo: JSON.parse(fs.readFileSync(path.resolve(__dirname, '../package.json'), 'utf8')), | ||
dataPath: __dirname, | ||
nameSuffix: '-dev', | ||
}; | ||
|
||
import settings from './settings.mjs'; | ||
|
||
import(process.argv[2] || '../dist/main.js').then(entry => { | ||
// See https://github.com/airdcpp-web/airdcpp-extension-js for usage information | ||
RemoteExtension( | ||
entry.default, | ||
!process.env.PROFILING ? settings : { | ||
...settings, | ||
logLevel: 'error', // Avoid spam while profiling... | ||
}, | ||
extensionConfig | ||
); | ||
}) | ||
|
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module.exports = { | ||
export default { | ||
// API settings | ||
url: 'ws://localhost:5600/api/v1/', | ||
username: 'myusername', | ||
|
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
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
Oops, something went wrong.