Questions tagged [git]
Git is a free & open source, distributed version control system designed to handle everything from small to very large projects with speed and efficiency.
1,055 questions
1
vote
1
answer
121
views
"error in libcrypto" for ssh-add with git-bash (mingw32) on Windows 11
I have a problem with SSH key usage for GIT on windows.
It works fine from windows GUI git clients.
From the terminal - git-bash / mingw32 - it fails with
$ git pull
git@<gitserver redacted>: ...
0
votes
0
answers
23
views
backblaze sync: how to ignore .git subdirectory
b2 command line tool, version 4.3.3
6.16.3-arch1-1
The old --exclude-regex is removed, and the .b2_ignore file is ignored.
I want to sync my directory to my b2 bucket but don't want to sync the git ...
1
vote
1
answer
85
views
How to fixup when there are duplicate commit subjects?
To reproduce:
Create two commits with the same commit message subject (that is, the first line of the commit message). Let's say the first commit gets commit ID "a", and the second one gets ...
1
vote
1
answer
60
views
How to control podman's images with git?
We are using podman's containers for the project.
The issue, we have is what while working on different branches of the project we need slightly different containers. So each git branch has its own ...
5
votes
0
answers
109
views
Subsequent "git clone" commands influencing each other?
I'm currently part of a migration from GitLab to Azure DevOps. As part of that I wrote a little bash script that iterates over the migrated git repos and for each performs a clone from both gitlab and ...
0
votes
0
answers
133
views
can't install pgAdmin4 desktop on arch linux
I need your help! I'm trying to install pgAdmin4 desktop version on my Arch system. I am getting libfakeroot internal error: payload not recognized! while building package for pgadmin4-server(which is ...
-1
votes
2
answers
436
views
how to filter git commits only if certain directories were changed
I need to filter commits based on directory changes, for example I need to get a list of commits only if the commit made a change in a certain directory.
I have tried the path filter glob option ...
4
votes
1
answer
153
views
How can I reverse forward git ssh when my config requires a Yubikey
I frequently need to log into a VM that has no direct access to the internet or our source code repo. In the past I have circumvented this with a reverse port forward over ssh but now my problem is ...
-1
votes
2
answers
101
views
extract multiple words from git log
I need to extract multiple words from git log.
I need the commit id and ticket number for each commit, I then need to run this through a loop and do some further processing for each commit.
commit ...
1
vote
1
answer
81
views
Git hook on SSH remote fails due to not reading shell configuration
I'm using a git post-receive hook to perform some actions
after a git push to a remote server. This remote operates
over SSH:
$ git remote -v
server user@server:repo.git
The problem is that ...
0
votes
2
answers
70
views
How to improve responsiveness of git hash in zsh prompt?
I wanted to put the current git hash in my prompt; but my initial approach was kind of laggy:
psvar[1]="$(git log -n1 --pretty='format: %h' 2>/dev/null)"
(with $PROMPT including %1v to ...
1
vote
1
answer
111
views
Configure git repository on production server with remote source
It may be a vague question, but I can't currently find a good solution in my head.
I have a BookStack application running on a company server. To simplify and for security I have a custom .gitignore ...
0
votes
1
answer
298
views
Why git diff does not work? fatal: bad revision '[6.1...]'
I want to compare 6.1(which is main) and my branch
git diff [6.1...] -- [/MM-pizdmr-are-up-to-date]
fatal: bad revision '[6.1...]'
I tried Github UI ,but it take too much time and suggested
git diff ...
0
votes
0
answers
145
views
LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection in macOS
when I run this command in Visual Studio Code in macOS 13.3.1, shows:
➜ texhub-web git:(main) git pull origin main
fatal: unable to access 'https://github.com/RedDwarfTech/texhub-web.git/': LibreSSL ...
0
votes
1
answer
42
views
How do I change the Subject/Title of patchwork patch?
I have created a patch for the Linux kernel. It can be found at the following website: https://patchwork.kernel.org/project/bluetooth/patch/[email protected]/
Unfortunately, I ...
0
votes
1
answer
45
views
How to check git porcelain on CI step?
I added this step to CI
check_if_there_is_change:
- run:
name: Check that no git-tracked files were modified
command: |
FILES_MODIFIED="$(git status --...
2
votes
0
answers
143
views
Git issue on FreeBSD 14.1
I've set up a FreeBSD 14.1 server with sources and ports tree. Then, after some port and package installations, I've tried to update the ports tree, in which purpose set up git and did git init in /...
0
votes
1
answer
89
views
Git SSL checks fail for one specific user
For a while now one specific user on my fedora 40 machine fails to clone any git repo at all with this error:
SSL certificate problem: unable to get local issuer certificate
Since the root user was ...
0
votes
1
answer
86
views
How to enable git gpg signing all commits from my computer
Background: It was years ago since I reinstalled my Linux Mint, now having couple months new installation of Linux Mint 22 Cinnamon, so I do not know if my question is specific to VS Codium which is ...
1
vote
0
answers
71
views
p4merge open each window minimized when running a git diff/ merge
I've asked the question on SO before, but maybe it is better placed here.
I'm running on Ubuntu 24.04.1 LTS (X11) and have p4merge installed in version p4v-2024.3.2656785.
I'm using p4merge since ...
0
votes
1
answer
152
views
Is it possible to make Windows git bash support chinese
I am trying to use curl (v8.6.0) to send the HTTP request to sever side under Windows git bash terminal. The server side is a Java spring boot application. When the curl JSON content contains Chinese ...
0
votes
1
answer
158
views
Neovim tabstops and git diff
I am new to vim and have difficulty setting it up.
I am working with a FRR code in which the tab is 8 spaces. I want to see 4 spaces instead of 8 and have added the following settings [options.lua]:
...
1
vote
1
answer
133
views
Zsh: completion not working for self-defined function based on git
In my .zshrc file I have written a function based on git log:
lg() {
git log \
--abbrev=12 \
--graph \
--oneline \
--color=always \
--format="%C(cyan)%h %C(blue)%ar %C(...
0
votes
0
answers
271
views
Have to run ssh-add every time I run some git command
I have followed the usual step of creating ssh keys adding the public ones to the provider(Github/Bitbucket etc). But for some reason this time I have to run ssh-add ~/.ssh/ each time I start my ...
0
votes
1
answer
91
views
On a fresh machine, which should come first the syncing of dotfiles or installation of their libraries?
This is a bit of a newbie question but I'm only starting out my journey with dotfiles!
Suppose I have a fresh machine and I want to sync my existing dotfiles/settings from some repo.
A dotfile may or ...
1
vote
2
answers
93
views
How to modify this git alias so it can be run without the need to put multiword commands in quotation?
I have this alias:
git config --global alias.all '!f() { ls -R -d */.git | xargs -I{} bash -c "echo {} && git -C {}/../ $1"; }; f'
It currently works fine when I run it like :
git ...
1
vote
0
answers
181
views
How to limit depth of `git diff --dirstat`
I have a git branch and I'd like to show how much of its changes are due to tests vs. implementation. I can run:
git diff master..my-branch --dirstat
and I get something like:
22.2% app/foo/abc/
...
1
vote
0
answers
122
views
Git ls-remote to github fails with classic "SHA-1 not supported" on tunneled ssh session but `ssh -T [email protected]` doesn't
Cross-posting from here as suggested by the community.
A bit of context: At my company we do tunneling to ssh into EC2 boxes. This tunneling command is as usual, uses ForwardAgent and the proxycommand ...
0
votes
2
answers
395
views
git clone error: bad line length character
I am trying to set up a GIT server in my LAN & use it with my Android phone through Termux.
My PC runs Fedora Silverblue 40.
Some tracelogs:
On my PC (all as user git):
$> ip addr show wlp5s0 ...
2
votes
1
answer
1k
views
git, merge changes from another (related) repo (says already up to date)
This is clearly one of those "I've missed the basic principle" type issues. Luckily since everything is now "on the web" I can be very specific and not need to say "for ...
1
vote
0
answers
31
views
heptapod: include version number in file name?
I'm trying to maintain an install script for Tryton ERP at Tryton community. I'd find it useful to have a version number in the file name; to manage this, when committing I'd like to have a prompt to ...
0
votes
1
answer
47
views
Track my slight changes to an external git repository I cannot push
I would like to use the code stored in an external git repository (I mean I am not a contributor for this code, I cannot push or create branches) but of course I need to change some files before ...
0
votes
0
answers
30
views
how to check the multi remote repo new commit when using git commit
I have a project with multi repo, when I commit with one of them, I just want to make sure each of the repo are newest, because the repo have some dependencies, I want to fetch all repo changes and ...
0
votes
1
answer
33
views
git diff tab completion of tags hides file name completion (using bash)
I am using git on Ubunto with bash shell, and a tab-completion using bind '"\t":menu-complete' in my .bashrc file. When I do git diff X, tab-completion starts cycling with matching git tags, ...
1
vote
1
answer
174
views
How can I change the output colors of `git branch -vv`
I see that it takes a --format argument:
--format <format>
A string that interpolates %(fieldname) from a branch ref being shown and the object it points at. The format is the ...
2
votes
2
answers
7k
views
Getting error when i load SSH key "Load key "/root/.ssh/id_ed25519": error in libcrypto"
Long story short I have an SSH key pair that I am copying to a new machine from a shared drive whenever the machine starts but when I load in the keys I keep getting an error. There is no difference ...
2
votes
1
answer
78
views
text formatter that supports bullets
I am looking for a formatter to use with my git commits. par pretty much does what I want, with the (important) limitation that I can't get it to properly format bullet lists, which are pretty common ...
0
votes
0
answers
116
views
git cli language default to first non english value
I have my computer language set to en_GB with fr_FR as backup only for spellcheck and money/measurement formatting purposes.
CLI apps work fine like that except git, who insist on using the first non ...
0
votes
1
answer
104
views
How can I call git's built-in diff command directly after configuring a different visual "git diff" substitute?
I have configured git diff to be a command that calls substitute diff for viewing file differences i.e /usr/bin/vim -dR "$2" "$3" and that doesn't work when I want to create a ...
0
votes
1
answer
161
views
Performing character-level comparison of "strings" without explicitly creating temporary files for git diff
Referring to this https://stackoverflow.com/a/31356602, I wrote this code:
#!/bin/bash
# Define the two strings to compare
string1="First string with some random text."
string2="Second ...
0
votes
1
answer
962
views
.Files.Glob pattern for a helm configmap
I have directory structure like this
$ tree .
.
├── Chart.yaml
├── datafiles
│ ├── index.html
│ ├── style.css
│ ├── exclude.txt
│ └── text
│ ├── file1.txt
│ ├── file2.txt
I want ...
0
votes
1
answer
116
views
How to add an exact-match flag to the following git + sed function?
I want to create a bash function where you can do a sed find and replace while ignoring the files and folders in .gitignore. I also want to be able to add any git grep flags to the command. For ...
1
vote
1
answer
3k
views
Why is my `git diff` now showing old mode and new mode instead of the differences in values of my local branch vs. master branch?
When I used to run git diff requirements.txt for the longest time it would show me the difference between the value of requirements.txt in my local git vs. master branch.
But now when I run it, I get:
...
1
vote
1
answer
141
views
Git can't run editor but it definitely exists
I've run into a very strange problem where Git says it start can't my editor, even though it definitely exists and works:
$ git config --global core.editor /usr/bin/nano
$ git rebase -i main
hint: ...
0
votes
1
answer
311
views
Git LFS doesn't work anymore with our Yocto: git doesn't fetch "large files" since we upgraded our tools
Git LFS doesn't work anymore with Yocto: git doesn't fetch "large files" since we upgraded our tools to these versions:
Yocto kirkstone
gitlab 16.7.3 and gitlab 16.8
git version 2.34.1
git-...
0
votes
1
answer
793
views
In a yocto recipe, what selects the release to download from the GitHub repository?
I'm using yocto to build my custom Linux distribution. I need to add hiredis to my distribution. hiredis is a minimalistic C client library for the Redis database, and I need it to access Redis by a C ...
0
votes
1
answer
318
views
Automatically add ssh key based on directory I'm in
I have two GitHub accounts. One for personal use, and another for business. Each is set up with its own SSH key gh_personal and gh_business inside ~/.ssh.
I have a personal project that sits in ~/code/...
2
votes
1
answer
2k
views
How to fetch from Git remotes without tags?
git fetch --all --no-tags doesn't do what it says on the tin, and keeps re-fetching tags every time I run it. How do I actually fetch from all remotes without fetching tags?
To reproduce:
Fork this ...
0
votes
1
answer
1k
views
After `su user`, getting `fatal: failed to stat : Permission denied` with `git push`
There's a lot of setup for this question:
I've got a host (rpi5.local) with 2 user accounts: pi and cake.
I wanted to explore git, and I created the cake account to "own" the "server/...
0
votes
2
answers
2k
views
Bash script for sending passphrase to unlock OpenPGP secret key
Ubuntu 22.04.1 LTS
When I do a git push REMOTE after a reboot, after a few seconds it comes up with a dialog box:
+---------------------------------------------------------------+
| Please enter the ...