Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6561401
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T13:34:56+00:00 2026-05-25T13:34:56+00:00

I’m probably doing something wrong. Scenario: 3 computers: server, laptop and firewalled machine, no

  • 0

I’m probably doing something wrong. Scenario: 3 computers: server, laptop and firewalled machine, no internet connection.

There’s a git repo on the server which I want to work on on the firewalled machine, in the end transferring changes made there back to the server.

What I’m doing now fails big time, it goes like this: I use the laptop, tar and a USB stick as transfer agents, a bit like this

laptop$ git clone http//server/.../project.git
laptop$ tar cvzf project.tar.gz project

then move the tar via USB to the firewalled machine, where I do:

fwm$ tar xvzf project.tar.gz
fwm$ cd project
fwm$ git branch -a
* master
  remotes/origin/x1
  remotes/origin/x2

So far, so good. But if I now want to checkout a certain branch (say, “x1”), I get the following message:

fwm$ git co x1
error: pathspec 'x1' did not match any file(s) known to git.

I can try to force my way via a full path, but that seems shaky, too:

fwm$ git co remotes/origin/x1
Note: moving to 'remotes/origin/x1' which isn't a local branch
If you want to create a new branch from this checkout, you may do so
(now or later) by using -b with the checkout command again. Example:
  git checkout -b <new_branch_name>

I say “shaky”, because

fwm$ git status
# Not currently on any branch.
nothing to commit (working directory clean)

What am I doing wrong and what would be the correct way in this scenario?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T13:34:57+00:00Added an answer on May 25, 2026 at 1:34 pm

    You’re not doing anything wrong you just haven’t created any local branches yet. All branches of the form <remote-name>/<branch-name> are remote branches and are supposed to only ever reflect some current or previous state of that branch on that remote, in your case origin/x1. Because of this you cannot make commits to these branches (if you did then they would no longer reflect a state of that branch on the remote at some point in the past) so git just doesn’t allow you to actually checkout those branches. Instead of puts you in a state known as a headless branch which you can commit to but if you switch branches your changes will be lost since you don’t have a branch name to reference (you can look up these commits in the reflog though).

    All you really have to do is create a local branch to work on after you untar the git repository, but this may be a good use case for git bundle

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have just tried to save a simple *.rtf file with some websites and
I want to count how many characters a certain string has in PHP, but
For some reason, after submitting a string like this Jack’s Spindle from a text
I am trying to understand how to use SyndicationItem to display feed which is
I used javascript for loading a picture on my website depending on which small
I have a jquery bug and I've been looking for hours now, I can't
Basically, what I'm trying to create is a page of div tags, each has

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.