Questions tagged [git]

Use this tag for questions about Git, a free and open source distributed version control system, related to using Git for topics such as continuous delivery, monitoring, building SDLC infrastructure, etc.

Filter by
Sorted by
Tagged with
1
vote
0answers
22 views

Jenkins release build on master branch fails with maven errors

I am trying to run a release build on the master branch of the repo PlatformObjects/ tracing-zipkin-config. In the Jenkins file when running the command: sh "mvn release:prepare release:perform -...
0
votes
0answers
4 views

Git Export Added/Modified Files

How to Export Added/Modified files between two git commits. I am using below command git archive --output=D:\export\changes5.zip HEAD $(git diff --name-only **SHA1** **SHA2** --diff-filter=ACMRTUXB)), ...
2
votes
1answer
27 views

When to “npm publish” when using git flow

I'm using the following resources as a guide to git flow: git-flow cheatsheet git-flow Using git-flow to automate your git branching workflow However, none of them explicitly mention at what point ...
0
votes
1answer
132 views

How to resolve merge conflicts in Azure DevOps current UI

I have followed the instructions on command line: https://docs.microsoft.com/en-us/azure/devops/repos/git/merging?view=azure-devops&tabs=visual-studio all I want to do is resolve this merge ...
1
vote
1answer
20 views

Jenkins Deployment Issue - Unrecognized SSL Message, Plaintext Connection?

I've been attempting to build and deploy a local copy of a repository, whilst still providing the remote depository to Jenkins, to a Tomcat version 9 server. I have both Jenkins and Tomcat running on ...
2
votes
0answers
9 views

Bitbucket: Is there any option to restrict deletion of release branch only after it is merged to master

We are using GitFlow workflow. After merging the release/* branch to master, we need to close the branch. For this task, we need to provide deletion access to pull request merger but in this case, ...
0
votes
0answers
45 views

Does GitHub support VFS for Git?

NOTES: I really hope that this question hasn't been asked before and as far as I know, only Azure DevOps Service (Azure DevOps on cloud) and Azure DevOps Server 2019 (Azure DevOps on-premise) fully ...
0
votes
2answers
225 views

Jenkins Pipeline - Clean before checkout - git clean -fdx “failed to remove: Directory not empty”

I have my Jenkins build configured to "Clean before Checkout" for its git source: Job Config > Source > git > Behaviours > Clean before checkout This results in Resetting working tree ...
3
votes
1answer
66 views

Deploying and testing features on a server by more than one developer

I have 4 environments (prod/preprod/SIT/DEV), also two main branches (Master & Develop), two developers work on features (One & Two). Developer One creates a feature (Feature A), he then ...
4
votes
2answers
210 views

JenkinsFile to get git branch name

I want to get git current checkout BRANCH NAME in my Jenkins file here is the code snippet... Here I am trying to push a file to my current branch I have tried many things could not find it... ...
4
votes
1answer
268 views

Multi-language Monorepo

We currently have a "front-end" git repository that is all of our JavaScript client apps, and a "back-end" git repository containing all back end APIs written in .NET Core. There is also a few other ...
1
vote
0answers
16 views

Parameterized git push to tfs

Is it possible to transmit additional strings/instructions to tfs with a parameterized git push? I think it can be managed by an instruction as part of the commit message, but I don't want to see ...
2
votes
1answer
62 views

Best solution for code develop

What is the best git solution for java code development? Make my own git server? Developers (Linux, Mac, Windows) are working on their local computers, then they are using my own git server. Would ...
0
votes
1answer
169 views

jenkins credentials not used as expected when cloning git repo

I am trying to setup a jenkins pipeline for my IaC code validation, for this I'd like jenkins to clone a gitlab (hosted) repository, for this purpose I setup a credential using username / key type, i ...
1
vote
1answer
103 views

Jenkins Git Client Plugin Issue

Git Client plugin previously was version was version:3.0.0-rc(beta) which has security vulnerabilities so upgraded to latest version:2.8.6 (latest). But unfortunately all the dependency plugins were ...
6
votes
1answer
173 views

What is the difference between DevOps and GitOps?

I am hearing nowadays a lot about GitOps. What is the difference between DevOps and GitOps? Is it just the SCM does the build and deploy when there is a commit instead of the CI/CD tool exclusively?
0
votes
2answers
343 views

Is there a way to use a Jenkinsfile from a git-submodule in a multibranch pipeline?

Background: The nature of our project's source involves multiple long-living branches, each one has its own Jenkins job (manually created). Multibranch limitation: Unfortunately we do not use a ...
1
vote
1answer
20 views

How to execute shell command or call URL on new gitlab issue?

I want to execute a shell command or call a URL when a user creates a new issue. The reason behind this is to synchronize our Gitlab issues with our CalDav calendar infrastructure. We are using Gitlab ...
0
votes
1answer
10 views

How to build Java project on existing virtual machine in Azure?

In my project we are using Azure DevOps in which we have a pipeline which pulls code from code repository downloads Ubuntu container installs Maven downloads all the dependencies then tries to build ...
2
votes
2answers
72 views

Git Release branching strategy for Continuous integration and deployment

We have tried multiple branching strategies to adopt CI/CD. Developers develop on the feature branch and then merging to master which get deployed to QA for testing and then master is deployed to ...
1
vote
2answers
102 views

Migrating from TFVS to GIT using GIT-TFS

We have a large TFS repository which we would like to migrate to git. We are considering using git-tfs for a while, in order for everything to continue working while we migrate. We have large (or ...
1
vote
1answer
800 views

Git-based CI/CD Pipeline for Monorepo

Are there established CI/CD strategies & best practices for working with a distributed team on a project that is utilizing monorepos? I can provide two specific use-cases: Working on content ...
0
votes
2answers
446 views

How do I configure Jenkins to trigger on a pull request based on the Git branch's name?

I want pull requests to Git where the target is master and the source has a string "foo" to trigger a Jenkins build. If this string "foo" appears in the source branch's name when there is a pull ...
4
votes
3answers
149 views

What options are available to encrypt the content of git repositories?

git-crypt, git secret were found. What is your personal preference and why? A couple of months ago, I have applied git-crypt. It was quite hard to set it up and the secrets are stored as binaries. I ...
2
votes
1answer
20 views

Commit messages from Submodules to Jenkins Change Log

I have a project with 3 submodules that are updated whenever that project is built and the project is built mainly for an installer (which is not in a submodule). Not a lot of changes are made in the ...
1
vote
0answers
18 views

How to mount ssh keys on ephemeral container from a Windows host? [closed]

I'm working on a container that uses Git to interact with some git repositories. But, to use Git it has to use the SSH keys that are stored on the Windows host machine. I tried two of the ways I could ...
0
votes
2answers
2k views

CI/CD pipelines Azure devops automatic merge after deploy release

I have a classic env. setup like following: I have 2 branches : Develop and Master. Is there any way in azure devops to setup the following rule: When a deploy is succeeded on dev environment (...
0
votes
3answers
122 views

Auto Deploy after push to git

I have some Codeigniter projects on some domains (on the same server), and the project is already in git. How to ensure server gets the new update when I push the code to git? Can anyone explain ...
1
vote
1answer
98 views

Gitflow with pull request or pull request

My team is currently using gitflow workflow into develop branch. Here is an overview for what we are doing. We are a sql server data warehouse team using Azure repos and Azure devops to build and ...
1
vote
2answers
2k views

How to trigger Jenkins Pipeline by push in specific branch in Bitbucket?

I've created Jenkins Pipeline Job, activated "Build when a change is pushed to BitBucket" trigger. I've also specified branches to build. But pipeline is triggered by all branch changes. Also I've ...
0
votes
2answers
55 views

How do I automate the process of pulling the latest code and restarting a service on git push?

I have an application (Logstash) running on a Linux VM and the settings for it are on a GitLab repo. What I want is for the VM to pull the latest version of the settings file and restart the service ...
1
vote
1answer
25 views

git - develop base and extended feature - commits in base should reflect in extended in pull

Hie I am working around in git to achieve something like mentioned below. Imagine there is a Big feature which is going to develop - since it's very big they have split into core feature and an ...
2
votes
3answers
226 views

What are the best practices of merging dev to master?

We have 2 branches (master/dev) + some feature branches and 2 environments (production/dev). Our team is a very small people. What are the best practices of merging dev to master? Every morning? ...
1
vote
1answer
22 views

TravisCI did not run after adding more configuration to .travis.yml file

I added some AWS keys to my .travis.yml file so that it would deploy my application over to ElasticBeanstalk, but after I committed the changes to the file and pushed to master, nothing happened. I ...
0
votes
2answers
196 views

Connecting GitHub to Jenkins running on docker toolbox

Started to learn DevOps 3 days ago, so I have a lot to learn! I have a jenkins running on docker toolbox container and I can access it via 192.168.99.100:8080. I configured a job and managed to use "...
0
votes
1answer
27 views

Github rest api post label gives error for array input

We are hosting GitHub enterprise for our development. I am able to access the reset api and create jira, create PR etc. When I try to add label to my PR, it gives error for array. curl -X POST -u ...
0
votes
2answers
55 views

How to keep original and new repositories in sync during a migration? (including the commit history)

We have a git repository that is currently hosted on Azure Devops and have to migrate it to our in house TFS 2017 git (the move is due to a business decision). But during this setup we need to run ...
8
votes
3answers
97 views

Should developer wait for CI pipeline to complete or start next task after pushing

My company is integrating CI/CD, so far we have implemented CI from what I understand. Currently when a developer pushes code to our git repo, the CI pipeline runs. Currently our CI pipeline include ...
1
vote
1answer
167 views

VSTS Azure for DevOps: Unit test checking mechanism on pull request

Is there a way in VSTS Azure for DevOps to implement unit test checking mechanism on pull request. The condition is to only allow commits that change something in the unittest folder for example. ...
0
votes
2answers
105 views

Automate creation of branch + pull-request

I have a repository (call it repo-X) of shell.nix files that define development environments for a number of separate projects (call them project-A, project-B). When one of the projects releases a ...
2
votes
2answers
252 views

Gitworkflow and testing short lived feature branches in Openshift/Kubernetes

Recently my team started adapting git workflow for agile-based delivery, we've been using JIRA, TeamCity and various other CI tools to complete the pipeline. The workflow works great for monolith or ...
0
votes
1answer
30 views

GitHub merge access

I am trying to create a GitHub workflow (not GitHub flow), where specific people will have merge only access to a branch in repo. I tried a few things, and I found that I can restrict users to read ...
3
votes
1answer
725 views

Run scripts which are stored in GitLab from Jenkins

I have configured Jenkins Build Jobs and Deployment Jobs from using Jenkins shell. But I put all the commands in Shell to execute. Can I store those commands in GitLab and execute from jenkins?
1
vote
1answer
45 views

Push specific changes (defect fix) and not feature changes

I am new to DevOps. I am using Jenkins and GitHub for salesforce deployment. Setup We have a develop branch. Feature branches are created out of it. When merged to develop, the deployment to the ...
1
vote
0answers
49 views

Appropriate use cases for git submodule and braid [closed]

For what use cases are git submodules (or subtrees) better suited than braid and vice-versa?
2
votes
1answer
290 views

Where is the git submodule revision actually stored?

I understand how to use git submodule to reference a specific commit in another repo, but where is that reference actually stored? It doesn't seem to be in .gitmodules as plain text?
1
vote
1answer
904 views

How to use Jenkins github user credentials to access github api in my script?

I have a Jenkins job foo that works perfectly well. It is authenticated with jenkins_foo_user. It is able to clone the repo and checkout the right branch. In my codebase, I have another script - ...
4
votes
1answer
309 views

How to implement GitLab Flow branching model for microservices?

Recently I’ve been looking into alternatives to the git flow branching model and since I’m already using GitLab, I stumbled upon their own branching model called GitLab flow. I’m currently trying to ...
0
votes
2answers
20 views

How to make one branch public while the others remain private on GitLab?

I am currently working on a LaTeX template. I chose gitlab to host the template. Now I want to give some colleagues access to my template, but only to the master branch. I use the other branches to ...
4
votes
3answers
264 views

Tips for separating DevOps Git repos?

We currently have a Git repo with automation code (with tests), iaas-code and lamba-code. The automation code is mostly Fabric, Python and unittests. The Iaas-code is mostly CloudFormation, Docker-...