Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use git stashes in git workflow for better performance #724

Merged
merged 71 commits into from Jan 19, 2020
Merged

Use git stashes in git workflow for better performance #724

merged 71 commits into from Jan 19, 2020

Conversation

@iiroj iiroj requested a review from okonet November 3, 2019 09:29
@iiroj iiroj mentioned this pull request Nov 3, 2019
@codecov
Copy link

codecov bot commented Nov 3, 2019

Codecov Report

Merging #724 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff          @@
##           master   #724   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files          13     13           
  Lines         429    429           
  Branches       97     97           
=====================================
  Hits          429    429

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 82bee06...f9e128d. Read the comment docs.

@fringd
Copy link

fringd commented Nov 8, 2019

hey what's the latest with excellent PR?

okonet
okonet previously approved these changes Nov 13, 2019
@okonet
Copy link
Collaborator

okonet commented Nov 13, 2019

@iiroj I'm ready to merge if you think it's complete. Just let me know if I should do the release. Also, did you add the BREAKING CHANGE marker?

@iiroj
Copy link
Member Author

iiroj commented Nov 14, 2019

@okonet since you experienced the bug with deleted files getting resurrected, maybe double-check that just in case after bbfae43. Theres a breaking change comment in 4fe53ef

lint-staged loses the MERGE_HEAD while stashing backups, so the current behaviour breaks merge conflict resolution. Solution is to manually check, save, and restore the MERGE_HEAD during runtime. This should be fixed and the test adjusted for successful run
@okonet
Copy link
Collaborator

okonet commented Dec 23, 2019

@iiroj thanks for the update. I'm wondering if this is somehow related to the behavior I saw with #750? WYT?

@iiroj
Copy link
Member Author

iiroj commented Dec 24, 2019

@okonet Yeah, I made a logic error in the improved error handling where the backup stash was dropped ("cleaned up") even though there were errors in the previous step. I'll improve it some, but since it's the holidays I'm not sure when. Probably push a commit now and then cleanup in about a week.

…ed (#762)

BREAKING CHANGE: Previously, lint-staged would allow empty commits in the situation where a linter task like "prettier --write" reverts all staged changes automatically. Now the default behaviour is to throw an error with a helpful warning message. The --allow empty option can be used to allow empty commits, or `allowEmpty: true` for the Node.js API.
# Conflicts:
#	package.json
@iiroj
Copy link
Member Author

iiroj commented Jan 13, 2020

What do you think, @okonet? There haven't been any new bug reports...

@okonet
Copy link
Collaborator

okonet commented Jan 14, 2020

I'd merge asap! We can iterate on a bigger user base. That should be a community effort and it should not stop us from shipping.

@iiroj
Copy link
Member Author

iiroj commented Jan 15, 2020

I'm in a good position right now in the sense that I have time to react to possible bugs after merging, so let's do it!

# Conflicts:
#	README.md
@iiroj
Copy link
Member Author

iiroj commented Jan 15, 2020

@okonet I'm not sure what squashing will do to the multiple breaking change comments, though. Should this just be merged without squashing?

@iiroj iiroj requested a review from okonet January 15, 2020 08:06
Copy link
Collaborator

@okonet okonet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

README.md Outdated Show resolved Hide resolved
@okonet
Copy link
Collaborator

okonet commented Jan 19, 2020

@iiroj yes, we should do a normal merge in this case since all commits are following the convention and the version will be calculated correctly.

@okonet
Copy link
Collaborator

okonet commented Jan 19, 2020

Feel free to merge (do not squash, please) when the build has passed.

@iiroj iiroj merged commit 072924f into master Jan 19, 2020
@okonet
Copy link
Collaborator

okonet commented Jan 19, 2020

🎉 This PR is included in version 10.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@taion
Copy link

taion commented Jan 20, 2020

I might be missing something, but I think 5208399 and 083b8e7 interact in an odd way.

I have a repo that includes a GraphQL schema. I want this schema to get regenerated on every commit to match the code.

Previously, I had a command like git add data/schema.graphql that would add my changes to the GraphQL schema.

Now, however, this gives me the warning added above.

I could switch to using a function here to add only the one file, but that would force me to opt out of using package.json to configure lint-staged, which I'd rather not do if I can avoid it.

@iiroj
Copy link
Member Author

iiroj commented Jan 20, 2020

@taion do you mean your lint-staged task automatically edits other files, and now they don’t get added? This might be so, because we only pass the original list of staged files to git add.

Can you open a new issue so we can discuss there?

@okonet
Copy link
Collaborator

okonet commented Jan 20, 2020

I think we still can allow git add . for such cases.

@taion
Copy link

taion commented Jan 20, 2020

Yup, I described it in more detail in #770.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment