From 3cf752f257de320314a2985a7d1257249647730a Mon Sep 17 00:00:00 2001 From: Artur Girenko Date: Thu, 31 Dec 2015 18:57:50 +0100 Subject: [PATCH] update .gitignore excluding generated files - env/dev - development only files regenerated by re-natal - index.*.js - figwheel-server.log --- re-natal.coffee | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/re-natal.coffee b/re-natal.coffee index e178ade..84fb4cd 100644 --- a/re-natal.coffee +++ b/re-natal.coffee @@ -217,6 +217,10 @@ copyFigwheelBridge = (projNameUs) -> exec "cp #{resources}figwheel-bridge.js ." edit "figwheel-bridge.js", [[projNameUsRx, projNameUs]] +updateGitIgnore = () -> + fs.appendFileSync(".gitignore", "\n# Generated by re-natal\n#\nenv/dev\nindex.android.js\nindex.ios.js") + fs.appendFileSync(".gitignore", "\n# Figwheel\n#\nfigwheel_server.log") + init = (projName) -> if projName.toLowerCase() is 'react' or !projName.match validNameRx logErr 'Invalid project name. Use an alphanumeric CamelCase name.' @@ -302,6 +306,8 @@ init = (projName) -> \"require('react-native/local-cli/cli').init('.', '#{projName}')\" " + updateGitIgnore() + generateConfig projName copyFigwheelBridge(projNameUs)