Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I didn't prevent same problem:

I don't use git rm projects.py and when i use :

git cp projectsTABTAB

projectsFindFrame.py projectsInsert.py

Also when i use:

git show a3ea2118bf1c5e2c6aa0974d0b6ff7415bd044ef

I prevent to content of projects.py file:

commit a3ea2118bf1c5e2c6aa0974d0b6ff7415bd044ef
Author: Mohsen Pahlevanzadeh <mohsen@debian>
Date:   Wed Oct 9 04:21:14 2013 +0330

    formValidators has been added, all of *_Insert component has been added to Projects() class.

diff --git a/projects.py b/projects.py
new file mode 100644
index 0000000..d76685b
--- /dev/null
+++ b/projects.py
@@ -0,0 +1,303 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+from tables import *
+from dbabslayer import *
+from languagecodes import *
+from PyQt4 import QtCore, QtGui
+    _fromUtf8 = QtCore.QString.fromUtf8
+except AttributeError:
+    def _fromUtf8(s):
+        return s
+    _encoding = QtGui.QApplication.UnicodeUTF8
+    def _translate(context, text, disambig):
+        return QtGui.QApplication.translate(context, text, disambig, _encoding)
+except AttributeError:
+    def _translate(context, text, disambig):
+        return QtGui.QApplication.translate(context, text, disambig)
+class Projects(QtGui.QMainWindow):

My Question is : Why i can't do git cp projects.py ? But it's to be.

share|improve this question
git does not have a git cp subcommand by default. What are you expecting it to do? There is an external git-cp subcommand implementation, which is just a shorthand for cp and git add. – Thomas Nyman Oct 25 '13 at 4:38
oh , So after tiwce TAB result get from filesystem files not local repository, thank you. – PersianGulf Oct 25 '13 at 17:55
up vote 1 down vote accepted

From your Tab completion results, it looks like projects.py isn't in the current checkout. Or at least, it isn't in the current directory. Say git ls-files | grep projects.py to find out if Git believes the file exists here and now, in your checkout.

If ls-files doesn't show the file, you need to find out which branch it is on.

If you cannot remember where it is, I recommend that you use a Git GUI to explore your tree, past and present. Once you know when the file existed, you will know where to go to copy it from.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.