From 965f2eb1fb4d8e9a6bf730925658f3a6baf50654 Mon Sep 17 00:00:00 2001 From: szymonrybczak Date: Fri, 19 Jan 2024 11:54:10 -0800 Subject: [PATCH] feat(template): add Yarn files to `.gitignore` (#42313) Summary: Recently inside React Native Community CLI we added bumping Yarn version inside `init` command, more information here: https://github.com/react-native-community/cli/pull/2134. In this Pull Request I added required rules in `.gitignore` for new projects created. ## Changelog: [GENERAL] [ADDED] - Add Yarn files to `.gitignore` in template Pull Request resolved: https://github.com/facebook/react-native/pull/42313 Test Plan: 1. Follow [Contributing guide](https://github.com/react-native-community/cli/blob/main/CONTRIBUTING.md) from React Native Community CLI repository to setup locally newest version of CLI. 2. Run this command: ```sh node /path/to/react-native-cli/packages/cli/build/bin.js init --template path/to/template ``` 3. Appropriate should be ignored. Reviewed By: NickGerleman Differential Revision: D52907962 Pulled By: cortinico fbshipit-source-id: f12dce8836e7e94257f8c690434b11227aa46446 --- packages/react-native/template/_gitignore | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/react-native/template/_gitignore b/packages/react-native/template/_gitignore index 0cab2ac6fc46cd..0b554f26428067 100644 --- a/packages/react-native/template/_gitignore +++ b/packages/react-native/template/_gitignore @@ -64,3 +64,11 @@ yarn-error.log # testing /coverage + +# Yarn +.yarn/* +!.yarn/patches +!.yarn/plugins +!.yarn/releases +!.yarn/sdks +!.yarn/versions