daily-code icon indicating copy to clipboard operation
daily-code copied to clipboard

Workflow/restrict lock files other than yarn

Open Rahul-Das-Sarma opened this issue 1 year ago • 13 comments

PR Fixes:

  • 1 1 Added Pre Script to check lock files such as pnpm.lock, bun.lockb ,package.lock to be restricted from committing.

Resolves #243

Checklist before requesting a review

  • [x] I have performed a self-review of my code
  • [x] I assure there is no similar/duplicate pull request regarding same issue

https://github.com/code100x/daily-code/assets/63789293/4a54447c-944b-41d7-9535-c0802e376589

Rahul-Das-Sarma avatar Apr 14 '24 14:04 Rahul-Das-Sarma

Any reason u got rid of yarn lock?

hkirat avatar Apr 14 '24 22:04 hkirat

It was showing merge conflicts. As yarn.lock file automatically gets generated during installation. Hence, decided to delete it. Please let me to know, if I need to re add it.

Rahul-Das-Sarma avatar Apr 15 '24 01:04 Rahul-Das-Sarma

automatically gets generated during installation

No, yarn need context of what version of packages are the packages inside ur package.json depend upon. Very risky thing to do

devsargam avatar Apr 15 '24 05:04 devsargam

I apologise, so if it's okay may I re-add it and push the code?

Rahul-Das-Sarma avatar Apr 15 '24 05:04 Rahul-Das-Sarma

Can u go back a commit and push the code? doing

yarn install

wont help

devsargam avatar Apr 15 '24 05:04 devsargam

Sure, I am doing it

Rahul-Das-Sarma avatar Apr 15 '24 05:04 Rahul-Das-Sarma

Hi, I have reverted the deletion. Please let me know if I need to do anything further. Thank you.

Rahul-Das-Sarma avatar Apr 15 '24 06:04 Rahul-Das-Sarma

Just copy over yarn lock from master and replace in this branch

hkirat avatar Apr 16 '24 12:04 hkirat

Adding it

Rahul-Das-Sarma avatar Apr 16 '24 12:04 Rahul-Das-Sarma

I have made the changes. I was thinking of adding commitlint as well to enforce standardized commit. Please let me know, if i should work on it

Rahul-Das-Sarma avatar Apr 16 '24 12:04 Rahul-Das-Sarma

I have made the changes. I was thinking of adding commitlint as well to enforce standardized commit. Please let me know, if i should work on it

Ahh... I think vs code is being vs code and thows lint issues very often. This will be twisting heads there?

SujithThirumalaisamy avatar Apr 19 '24 15:04 SujithThirumalaisamy

@SujithThirumalaisamy the lint issues is due to prettier eslint conflicts

devsargam avatar Apr 19 '24 15:04 devsargam

I don't know about😁.. that but this can definitely help contributors learn about commit lint and write proper commit messages. But it is definitely not mandatory thing

Rahul-Das-Sarma avatar Apr 19 '24 15:04 Rahul-Das-Sarma

/bounty $15

hkirat avatar Apr 21 '24 20:04 hkirat