Tag: push

Is it possible to use Git between two workstations, without a “central” repository?

I made the move from SVN to Git for some home programming, setting up a Git repository on my ReadyNAS drive. I then created a repository, which I cloned onto two different laptops. These laptops both have changes that are committed but not pushed back to the central repository; this is because the central repository […]

Push a newly created file into git repository

I have created a git repository of a linux directory and pushed all files into it. I have recently moved a new file into that linux directory and now want to push this new file into its git repository. I am trying to do so by typing git push origin master in the command line […]

Disable password prompt for git pull, but not for push

Is it possible to prompt for a password when running: git push -u origin master but not when running: git pull origin master ? I would like my developers to be able to keep the dev sites up to date without allowing them to push changes to the origin. Thanks.

Git added git HEAD and repo info to files

I have looked around and can’t seem to find an actual solution. I’ve found one or two examples of people with similiar issues but no reasoning to why it happened. Before I show the issue, let me explain what I did: Pushed a commit from my dev server to the repo to use on my […]

Will Git Force push overwrite/delete tags

Will a force push to master overwrite/delete tags created earlier?

GIT, merged two branches, pushed on server, now how to unmerge them

Need urgent help in GIT i have my code in master branch, then there is another branch named dev, dev is ahead of few commits than my master branch, before merging i even took a master branch backup ‘master-backup’ then i merge dev into master, and push the merged master branch onto server (git push […]

JGit: Push to specific branch

I have two branches on github: master and development. I want to push a newly created file to the development branch. String user = “user”; String password = “password”; String localPath = “local”; String remotePath = “https://github.com/some/git.git”; Git.cloneRepository().setBranch(“refs/heads/development”).setURI(remotePath).setDirectory(new File(localPath)).call(); Git localGit = Git.open(new File(localPath)); localGit.checkout().setName(“origin/development”).setUpstreamMode(SetupUpstreamMode.TRACK).call(); new File(“local/test”).createNewFile(); localGit.add().addFilepattern(“.”).call(); localGit.commit().setMessage(“message”).call(); localGit.push().setCredentialsProvider(new UsernamePasswordCredentialsProvider(user, password)).call(); What I get […]

git push –set-upstream vs –set-upstream-to

according to this article, git push –set-upstream is deprecated and git push –set-upstream-to should be used instead. But when I checked the git push documentation, I can only find –set-upstream, but –set-upstream-to is no where to be found. So is –set-upstream deprecated? Should I use –set-upstream or –set-upstream-to?

Invalid file descriptor problem with Git on Windows

I’ve been using Git on Linux for about a year, and everything works fine. Since recently, a colleague has joined development and he’s using Windows. Everything works fine there as well, but sometimes when he tries to push changes to a remote repository (bare) on Linux server it bails out with ‘Invalid file descriptor’ message. […]

“Connection refused – connect(2) (Errno::ECONNREFUSED)” when pushing to the remote git server from gitlab

I started gitlab with: rvmsudo -u git -H bundle exec rake gitlab:setup RAILS_ENV=production When I create a new project, I get the remote repo url: git remote add origin ssh://git@gitlab.mydomain.com:12035/root/my_project.git (so not the default 22 ssh port, but 12035) So when I try to push it to the gitlab: git push –verbose -u origin master […]

Git Baby is a git and github fan, let's start git clone.