Skip to main content
replaced http://stackoverflow.com/ with https://stackoverflow.com/
Source Link

If it is part of your project, I would make a branch or a tag and then delete that code from your main repo.

I used to keep blocks of code in my main repo that served no other purpose other than that they might be needed later. Really what I was saying was that it might be useful later and I needed to find it. A tag might be even better as branches are supposed to be more ephemeral. Branch vs TagBranch vs Tag

In any case unused code will just confuse you and other devs later. So it's not a great practice to leave it in a project.

If it is part of your project, I would make a branch or a tag and then delete that code from your main repo.

I used to keep blocks of code in my main repo that served no other purpose other than that they might be needed later. Really what I was saying was that it might be useful later and I needed to find it. A tag might be even better as branches are supposed to be more ephemeral. Branch vs Tag

In any case unused code will just confuse you and other devs later. So it's not a great practice to leave it in a project.

If it is part of your project, I would make a branch or a tag and then delete that code from your main repo.

I used to keep blocks of code in my main repo that served no other purpose other than that they might be needed later. Really what I was saying was that it might be useful later and I needed to find it. A tag might be even better as branches are supposed to be more ephemeral. Branch vs Tag

In any case unused code will just confuse you and other devs later. So it's not a great practice to leave it in a project.

Source Link
unflores
  • 402
  • 2
  • 9

If it is part of your project, I would make a branch or a tag and then delete that code from your main repo.

I used to keep blocks of code in my main repo that served no other purpose other than that they might be needed later. Really what I was saying was that it might be useful later and I needed to find it. A tag might be even better as branches are supposed to be more ephemeral. Branch vs Tag

In any case unused code will just confuse you and other devs later. So it's not a great practice to leave it in a project.