Skip to content

Commit 7691e3a

Browse files
Amend hooks and log message
1 parent 1a2e3d0 commit 7691e3a

File tree

4 files changed

+16
-9
lines changed

4 files changed

+16
-9
lines changed

README.MD

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,15 @@ AndroidManifest.xml is automatically updated to use the new MainActivity.
2323
Credits
2424
==
2525
Based on cordova-android-fragments (https://github.com/rajivnarayana/CordovaFragments)
26+
27+
History
28+
==
29+
30+
0.0.2
31+
--
32+
- Correct log message
33+
- Add history to README
34+
35+
0.0.1
36+
--
37+
Initial release

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "cordova-plugin-android-fragmentactivity",
3-
"version": "0.0.1",
3+
"version": "0.0.2",
44
"description": "An android plugin that provides a replacement activity to the default activity to start a cordova application with MainActivity as a Fragment Activity. Useful when you want to add native views on top of cordova webview.",
55
"cordova": {
66
"id": "cordova-plugin-android-fragmentactivity",

plugin.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0" id="cordova-plugin-android-fragmentactivity" version="0.0.1">
2+
<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0" id="cordova-plugin-android-fragmentactivity" version="0.0.2">
33

44
<name>Cordova Android FragmentActivity Plugin</name>
55
<description>An android plugin that provides a replacement activity to the default activity to start a cordova application with MainActivity as a Fragment Activity. Useful when you want to add native views on top of cordova webview.</description>

scripts/android/afterPluginInstall.js

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,8 @@ module.exports = function(context) {
3434

3535
console.log(newActivityPath);
3636

37-
fs.writeFile(newActivityPath, newActivity, function(err) {
38-
if (err) {
39-
return console.log(err);
40-
}
41-
42-
console.log("New MainActvity generated.");
43-
});
37+
fs.writeFileSync(newActivityPath, newActivity);
38+
console.log("New MainActivity generated.");
4439
});
4540
}
4641
};

0 commit comments

Comments
 (0)