forked from apla/me.apla.cordova.app-preferences
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Hook for plugin add/rm will be used when every plugin is installed, need to use install/uninstall
- Loading branch information
Showing
6 changed files
with
53 additions
and
25 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 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,27 @@ | ||
'use strict'; | ||
|
||
module.exports = function (context) { | ||
var req = context.requireCordovaModule, | ||
Q = req('q'), | ||
path = req('path'), | ||
fs = require("./lib/filesystem")(Q, req('fs'), path), | ||
settings = require("./lib/settings")(fs, path), | ||
android = require("./lib/android")(fs, path, req('elementtree'), req('cordova-lib/src/cordova/util'), req('cordova-lib').configparser), | ||
ios = require("./lib/ios")(Q, fs, path, req('plist'), req('xcode')); | ||
|
||
return settings.get() | ||
.then(function (config) { | ||
return Q.all([ | ||
android.afterPluginInstall(config), | ||
// ios.afterPluginInstall(config) // not implemented for iOS | ||
]); | ||
}) | ||
.catch(function(err) { | ||
if (err.code === 'NEXIST') { | ||
console.log("app-settings.json not found: creating a sample file"); | ||
return settings.create(); | ||
} | ||
|
||
throw err; | ||
}); | ||
}; |
File renamed without changes.
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