How to refactor your repository:

The goal it to keep the code of all sites in identical structure. This way we will be able to edit and search easily in any repository we need.

1. Final decision:

You don't have to refactor your repository completely, you can edit/refactor names of files and folders during your sprint tasks.

2. Rebuild Structure:

we are following more or less the structure of path in the CMS:

boost.naturalint.com/sites/80/index#comp-content

The changes are described below:

80 - the number of the site. We will add a folder that includes the name (because we can’t really track sites by id - it's not relevant for us at the moment). Example: bankingFR > …

Index - the page. As you can see, the url doesn’t include the page type, in that case: chart page. We will add the page type so it would be easier for us to find the page we need. Example: chartPage > index (folder)

Comp-content - we will add a file for the component with its name (for example, review component) and number of variant and name. Example: reviewComponent_v1_defult.html.

Pay attention(!):

v1 - stands for the variant that appears here:

Please make sure you follow this structure, you can take example from the updated top-10 repo (master).

3. Before uploading to master:

Run the following lines in terminal in order to make sure your Mac doesn’t store the files you just deleted:

# remove any existing files from the repo, skipping over ones not in repo

find . -name .DS_Store -print0 | xargs -0 git rm -f --ignore-unmatch

#add .gitignore

git add .gitignore

#commit message on what was deleted

git commit -m '.DS_Store banished!'

After getting a message on what was deleted, your code is ready to be checked and finally merged.

Enjoy.

results matching ""

    No results matching ""