3 ms·
I'm not following your line of questioning. Without ever using github as an online editing platform, you can do one push with two new commits.
by recursive 1mo ago
I'm not following your line of questioning. Without ever using github as an online editing platform, you can do one push with two new commits.
- Brian_K_White 1mo agoCommits are not expensive, pushes are. You can do any number of commits before you do one push, unless you are editing online, in which case every act is it's own commit & push. You can rig up a local ide to pathologically commit+push per save, but you can do literally anything, so what you can do is immaterial.
- leptons 1mo ago>You can rig up a local ide to pathologically commit+push per save The dev system we use for a 3rd party hosting provider (a big one) requires a commit and push for every file save while we're developing. I created a build system for this that copies the whole repo to a temp folder. As we save changes to files in the main repo folder, the build system watches for changes and copies the changed file to the temp folder, then does a commit on the temp folder and pushes to a an intermediary repo in github which then triggers an action that causes the 3rd party system to update from the intermediary repo. This way we don't pollute our main source repo with a commit every time we save an update to a source file. It's not my favorite way to develop but it's caused us no real problems except when github goes down.
- ninkendo 1mo ago> requires a commit and push for every file save I don’t think I could imagine a stupider idea than this if I tried. To paraphrase Babbage: I am not able rightly to apprehend the kind of confusion of ideas that could provoke such a solution.
- Brian_K_White 1mo agomeh, it's just external undo button. It's useful. It might or might not be worth the cost, but it's not that it delivers no value or causes some harm (other than cost/reliability)
- esafak 1mo agohttps://delta.dev/ https://delta.dev/
- orf 1mo agoDo you have some GitHub architectural knowledge you’d like to share with us? A push pushes commits and blobs and trees and tags. It’s an interesting metric to track, but the core unit of complexity (and expense) worth tracking on GitHub’s side is obviously the commit. There’s a difference between pushing 1 commit and 100.
- jeremyjh 1mo ago> There’s a difference between pushing 1 commit and 100. There isn’t much. GitHub doesn’t run actions separately for each commit. It runs them on pushes. I’m trying to think of a thing that would happen for each commit in each push and coming up blank. It does things like scan for references to issues to index, but it would just scan the log for a range. I did disagree with GP though because there is no reason to assume that the ratio of commits to pushes has materially changed. So if that is the proxy they have always used for measuring growth, and they know it reliably does that then I think it’s a reasonable way to communicate this to this audience.
- orf 1mo ago> It runs them on pushes Sure, because pushes are how you update a reference. That’s really what triggers an action: a reference changing. And there could be a bunch of those in a push. A commit costs storage, you’ve got secret scanning, it needs to be indexed in a way that can be referenced in commit messages and comments, a commit message itself can close issues or reference other PRs, stored and served individually and immediately via the web UI or git clients, etc etc. It’s also like… the core unit of git.
- jeremyjh 1mo agoNone of the things you mention - indexing or secret scan would be done individually for each commit. As I already said, this would be a log of all commits in the range pushed - it would be scanned once for those things. There is no need for a loop running over a range of commits and processing each one.
- meerita 1mo agoExactly. You can have 3000 commits in a branch, and unless you don't push each of them one by one, shouldn't be a problem the number.