adamchainz, to random
@adamchainz@fosstodon.org avatar

♦️ Yay, my force push blog post was featured in this week’s @pythonbytes ! 🥳

https://pythonbytes.fm/episodes/show/384/force-push-lightly

adamchainz, to python
@adamchainz@fosstodon.org avatar

🐍♦️ Use Git to pass pytest a list of all modified test files:

pytest $(git diff --name-only '/test_.py')

Adjust the pathspec (Git’s “glob” syntax) if you have a different test file naming convention.

joeyh, to random
@joeyh@hachyderm.io avatar

now considers a symlink to "git~1" something git fsck should warn about, on Linux, because on Windows, that happens to be a way to refer to the .git directory.

rotfl

joey@darkstar:/tmp/foo>ln -s git1 foo
joey@darkstar:/tmp/foo>git add foo
...
joey@darkstar:
/tmp/foo>git fsck
Checking object directories: 100% (256/256), done.
warning in blob 086654741cca64b19ba88286fce998d933897870: symlinkPointsToGitDir: symlink target points to git dir

tomodachi94, to random
@tomodachi94@floss.social avatar

What's the Git GUI of choice for Git newbies nowadays? I'm trying to help out someone who wants to contribute to a GitHub project.

craigbro, to random
@craigbro@emacs.ch avatar

Recent CVE in allowing RCE when cloning a repo, see https://github.com/git/git/security/advisories/GHSA-8h77-4q3w-gfgv

Note it says, "As always, it is best to avoid cloning repositories from untrusted sources."

Now consider how many languages will clone a repo of a transitive dependency, or direct dependency at time of dep resolution -- often before any dep analysis/presentation tools could give you a means to evaluate the transitive git deps.

Like , one of my favorites. I have not review dep resolution/fetch code in other languages, but it seems that they should all heed the advice in that advisory.

nobodyinperson, to random
@nobodyinperson@fosstodon.org avatar

🍿

> git annex assist
...
symlinkPointsToGitDir: symlink target points to git dir
remote: fatal: fsck error in pack objects
error: remote unpack failed: unpack-objects abnormal exit

IIUC, :git: implemented something that uselessly breaks :gitannex: / :datalad: compatibility on the remote side, amazing! 🤦

https://github.com/git/git/commit/a33fea0886cfa016d313d2bd66bdd08615bffbc9

Initial report:

https://git-annex.branchable.com/forum/Strange_symlinkPointsToGitDir_error/#comment-12ed3e72e46de9b086da51455f20b26b

@joeyh @mih @chrysn

tmaz, to random French
@tmaz@piaille.fr avatar

Le saviez-vous ?
Git ≠ Github

Vous pouvez versionner votre code sans travailler gratuitement pour les actionnaires de Microsoft et compagnie.

Par exemple, et notamment pour vos projets libres : https://codeberg.org/ (c'est une asso berlinoise)

➡️ @Codeberg

mmarif, to android
@mmarif@mastodon.social avatar

GitNex 5.5.0 is now OUT with a new comment UI, the ability to update your profile avatar, the option to insert notes to issues/PRs/releases, and many other improvements.

We have also reached 400 stars on . Thanks to all for supporting GitNex all the way.

With the upcoming 6.0.0 release, GitNex will have different version numbers, such as 6.0.0, 7.0.0, and so on.

I hope you enjoy the new release and find it even more productive.

New comment UI

adamchainz, to random
@adamchainz@fosstodon.org avatar

♦️ There is a safer alternative to 'git push --force'!

🫸 Use --force-with-lease and --force-if-includes to restrict force pushes so that they don’t unintentionally overwrite commits pushed by others.

Explained in my post: https://adamj.eu/tech/2023/10/31/git-force-push-safely/

heptapod, to random
@heptapod@fosstodon.org avatar
opdavies, to random
@opdavies@mastodon.social avatar
anthony_steele, to CSharp
@anthony_steele@dotnet.social avatar

Automating in code on commit with format, and .NET

https://www.anthonysteele.co.uk/HuskyAutoformat

When I wrote this about a month ago, I didn't geta round to linking it from the index https://www.anthonysteele.co.uk/

So, now I have.

This is detailed, step-by-step instructions of getting this set up, with screenshots to help with commands and outcomes. An "idiot's guide" if you like, because I was that idiot.

Ric, to opensource
@Ric@awscommunity.social avatar

What we need is cross forge/hub forking! When do we want it now!

season 1 nbc GIF by The Good Place with the main character saying “ah, fork me”

badrihippo, to random
@badrihippo@fosstodon.org avatar

Do we have a for public repos? :git:

Right now my "default" is to go to GitHub, and then maybe GitLab and Codeberg...but that leaves out all the other hosts out there. Once happens we'll need it even more :fedi:

(By the way, I say "git" because that's where most code is, but if other kinds of repos are supported, even better! 🔍 )

adamsdesk, to linux
@adamsdesk@fosstodon.org avatar

Quickly Jump From Local Git Repository to Website

Improve your git workflow with a simple shell function that can quickly jump you from the terminal of a local git repository to the project's website.

https://www.adamsdesk.com/posts/open-repository-website/

amyfou, to Mac
@amyfou@lingo.lol avatar

Hello friends I am now the mortal enemy of every one of these gd .DS_Store files 🤕 🥊 💪

#mac #git #complaints #yesIGITIGnoredIt #NoThatDoesNotStopThem

bbelderbos, to github
@bbelderbos@fosstodon.org avatar

🚀 Quickly jump from your local #git repository to its corresponding GitHub page with this handy shell alias! ✨

🔗 Add openrepo to your shell profile or rc file, source it, and now you can simply type openrepo in your terminal to open your GitHub repo. 😎

#GitHub #DevTip

opdavies, to random
@opdavies@mastodon.social avatar
Andres4NY, to random
@Andres4NY@social.ridetrans.it avatar

I wish that when I reverted a revert, was smart enough to attribute things to the original author.

That is, person A does a commit; git blame foo.c shows the lines as being changed by person A. Person B reverts that commit (temporarily), and then later on person B reverts the revert (thereby putting person A's changes back in). But now when you git blame foo.c, the line change is from person B.

[I know you can manually set --author or whatever, but I feel like it should be automatic.]

zeroiee, to programming
@zeroiee@techhub.social avatar

A clean Git history is the key to successful teamwork and quick bug fixes. Errors can only be successfully tracked down if it is always possible to trace when and where code was changed by whom and for what reason.

🥴 However, in the rush of the battle, the changes that are packaged in a commit are sometimes not taken very seriously. Who has never experienced this? A change that is actually unrelated to the current work package has made it into the commit because the file has already been saved temporarily.

💡The solution: With an "interactive add" (git add -i), you can pack partial changes ("hunks") into a commit and specify line by line what should be included in the next commit.

:git: "Staging patches": https://git-scm.com/book/en/v2/Git-Tools-Interactive-Staging

#git #zeroiee #code #programming #opensource #sourceControlManagement #codeManagement #versionManagement #versioning

kernellogger, to linux
@kernellogger@fosstodon.org avatar

A question for experts on #git bisecting the #Linux #Kernel:

Assume someone runs into a regression when updating from 6.1.90[1] to 6.6.30 that needs bisecting. What do you suggest:

  • Check manually which mainline release (e.g. 6.2, 6.3, ...) introduced the problem and afterwards bisect between that and the previous release.

  • Bisect straight between 6.1 and 6.6.30.

1/ I guess I would definitely go for…

[1] let's assume that 6.1 was fine for this scenario to keep things simpler

amoroso, to random
@amoroso@fosstodon.org avatar

I know, Git is a mess. But, since we're stuck with it, we may as well try to learn how it works with resources like this, which aims to lead to some form of Git enlightenment.

https://think-like-a-git.net

root42, to random
@root42@chaos.social avatar

Is there a way to resolve cherrypick conflicts purely on the command line, without using a merge tool by saying „use theirs“? Or „keep upper“?

civodul, to random
@civodul@toot.aquilenet.fr avatar

Finn Landweber wrote a pretty cool variant of the ‘guix git authenticate’ method:
https://codeberg.org/flandweber/git-verify

Highlights: Haskell instead of Scheme, JSON instead of sexps, SSH instead of OpenPGP, additional features such as per-file authorizations and unsigned merge commits.

👍

tom, to Logseq German
@tom@swiss.social avatar

Dear and users,
is not a backup system. Store your notes in a reposotory, if you must, but please configure a backup for your notes.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • JUstTest
  • kavyap
  • DreamBathrooms
  • thenastyranch
  • magazineikmin
  • tacticalgear
  • khanakhh
  • Youngstown
  • mdbf
  • slotface
  • rosin
  • everett
  • ngwrru68w68
  • Durango
  • megavids
  • InstantRegret
  • cubers
  • GTA5RPClips
  • cisconetworking
  • ethstaker
  • osvaldo12
  • modclub
  • normalnudes
  • provamag3
  • tester
  • anitta
  • Leos
  • lostlight
  • All magazines