-
Notifications
You must be signed in to change notification settings - Fork 614
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Mark Anderson <[email protected]>
- Loading branch information
Showing
8 changed files
with
201 additions
and
49 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 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,9 +1,31 @@ | ||
/* eslint-disable no-undef */ | ||
module.exports = { | ||
...require('@ionic/swiftlint-config'), | ||
// eslint-disable-next-line no-template-curly-in-string | ||
included: ['${PWD}/ios/Plugin'], | ||
identifier_name: { | ||
min_length: 1, | ||
min_length: { | ||
warning: 3, | ||
error: 1, | ||
}, | ||
}, | ||
excluded: ['node_modules', 'ios/Pods'], | ||
opt_in_rules: [ | ||
'implicitly_unwrapped_optional', | ||
'file_name_no_space', | ||
'force_unwrapping', | ||
'function_default_parameter_at_end', | ||
'lower_acl_than_parent', | ||
'modifier_order', | ||
'overridden_super_call', | ||
'unowned_variable_capture', | ||
'unused_import', | ||
], | ||
line_length: { | ||
warning: 150, | ||
error: 300, | ||
ignores_function_declarations: true, | ||
ignores_comments: true, | ||
ignores_interpolated_strings: true, | ||
ignores_urls: true, | ||
}, | ||
}; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
{ | ||
"tasksRunnerOptions": { | ||
"default": { | ||
"runner": "nx/tasks-runners/default", | ||
"options": { | ||
"cacheableOperations": ["build"], | ||
"parallel": 1 | ||
} | ||
} | ||
}, | ||
"targetDefaults": { | ||
"build": { | ||
"dependsOn": ["^build"], | ||
"outputs": [ | ||
"{projectRoot}/action-sheet/dist", | ||
"{projectRoot}/app/dist", | ||
"{projectRoot}/app-launcher/dist", | ||
"{projectRoot}/browser/dist", | ||
"{projectRoot}/camera/dist", | ||
"{projectRoot}/clipboard/dist", | ||
"{projectRoot}/device/dist", | ||
"{projectRoot}/dialog/dist", | ||
"{projectRoot}/filesystem/dist", | ||
"{projectRoot}/geolocation/dist", | ||
"{projectRoot}/google-maps/dist", | ||
"{projectRoot}/haptics/dist", | ||
"{projectRoot}/keyboard/dist", | ||
"{projectRoot}/local-notifications/dist", | ||
"{projectRoot}/motion/dist", | ||
"{projectRoot}/network/dist", | ||
"{projectRoot}/preferences/dist", | ||
"{projectRoot}/push-notifications/dist", | ||
"{projectRoot}/screen-orientation/dist", | ||
"{projectRoot}/screen-reader/dist", | ||
"{projectRoot}/share/dist", | ||
"{projectRoot}/splash-screen/dist", | ||
"{projectRoot}/status-bar/dist", | ||
"{projectRoot}/text-zoom/dist", | ||
"{projectRoot}/toast/dist" | ||
] | ||
} | ||
}, | ||
"$schema": "./node_modules/nx/schemas/nx-schema.json", | ||
"namedInputs": { | ||
"default": ["{projectRoot}/**/*", "sharedGlobals"], | ||
"sharedGlobals": [], | ||
"production": ["default"] | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import { glob } from 'glob'; | ||
import { promises as fs } from 'fs'; | ||
|
||
// Define the search pattern | ||
const searchPattern = '**/android/settings.gradle'; | ||
|
||
// Define the string to search for and the string to replace it with | ||
const searchString = `new File('../node_modules/@capacitor/android/capacitor')`; | ||
const replacementString = `new File('../../node_modules/@capacitor/android/capacitor')`; | ||
|
||
(async () => { | ||
try { | ||
// Search for all files that match the pattern | ||
const files = await glob(searchPattern); | ||
// For each file that matches the pattern | ||
for (const file of files) { | ||
try { | ||
// Read the file | ||
let data = await fs.readFile(file, 'utf8'); | ||
|
||
// Replace all instances of the search string with the replacement string | ||
let result = data.split(searchString).join(replacementString); | ||
|
||
// Write the result back to the file | ||
await fs.writeFile(file, result, 'utf8'); | ||
} catch (err) { | ||
console.error('Error while processing file:', err); | ||
} | ||
} | ||
} catch (e) { | ||
console.error('Error while searching for files:', e); | ||
} | ||
})(); |
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,33 @@ | ||
import { glob } from 'glob'; | ||
import { promises as fs } from 'fs'; | ||
|
||
// Define the search pattern | ||
const searchPattern = '**/ios/Podfile'; | ||
|
||
// Define the string to search for and the string to replace it with | ||
const searchString = '../node_modules/@capacitor/ios'; | ||
const replacementString = '../../node_modules/@capacitor/ios'; | ||
|
||
(async () => { | ||
try { | ||
// Search for all files that match the pattern | ||
const files = await glob(searchPattern); | ||
// For each file that matches the pattern | ||
for (const file of files) { | ||
try { | ||
// Read the file | ||
let data = await fs.readFile(file, 'utf8'); | ||
|
||
// Replace all instances of the search string with the replacement string | ||
let result = data.split(searchString).join(replacementString); | ||
|
||
// Write the result back to the file | ||
await fs.writeFile(file, result, 'utf8'); | ||
} catch (err) { | ||
console.error('Error while processing file:', err); | ||
} | ||
} | ||
} catch (e) { | ||
console.error('Error while searching for files:', e); | ||
} | ||
})(); |