5

This post is related to downloading files from Git Repository on Ubuntu 11.10.

I have installed 'Git' from Software Centre including the components like GUI, revision tree visualiser etc etc

The files I am downloading are from the following Repo

From Terminal I can clone the repository by issuing following command

khurram@CP:~/GitRepos$ git clone https://github.com/commonsguy/cwac-wakeful.git

So

  1. This repository has a jar file in downloads section of the git. But the above command doesn't download those file so I have to do that manually. How can I download the said jar file or any other file for that matter automatically.

  2. Can some one share a script to check for updates on git repository to download files.

  3. How can I invoke the GUI component of my git installation.

  4. Does Linux have something like Tortoise SVN. I have used Tortoise SVN for Subversion in Windows and it integrates to the Explorer. It shows a little red marker on the folder to indicate that it is out-of-sync. Hence I can just right click on the folder to update from repository.

3
  • 1
    You have several questions here. Some of which have already been answered. Mar 6, 2012 at 18:09
  • Yes I checked the links. Thanks all of you for pointing out the answers. Very impressed with quick help. Mar 8, 2012 at 12:25
  • You're welcome! In the future it's typically preferred that questions with lots of sub questions are broken out in to their own questions. Makes it easier if someone knows an answer to one of your bullets and not another :) Mar 8, 2012 at 12:28

3 Answers 3

7

Let me see if I can address how this works.

  1. The contents of the JAR are the repo. It makes no sense from a source control aspect to put the JAR which is the repo in to the repo. If all you want to do is download the JAR then something like this:

    wget https://github.com/downloads/commonsguy/cwac-wakeful/CWAC-WakefulIntentService.jar
    

    would suffice.

  2. You can check for updates at any time with git fetch, you can pull down changes with git pull

  3. Make sure you've installed git-gui Install git-gui package and run git gui from the command line.

  4. Nautilus Git Integration

4
  • I found the wget command. It works fine. Is there any way to compare the two files on-line vs local copy to download the file from internet only if its updated/new Mar 6, 2012 at 18:36
  • 1
    It is incorrect to say that the repo is the jar. The repo is a version controlled collection of source files. The jar file is the executable that results from compiling ( some version of ) the source files.
    – psusi
    Mar 6, 2012 at 20:40
  • @psusi The source files make the jar though, in this case. Mar 6, 2012 at 20:45
  • 1
    @MarcoCeppi, right, but just because you can use a hammer and nails to turn wood into a house does not mean wood is a house.
    – psusi
    Mar 6, 2012 at 22:07
1

Here it goes:

  1. The jar file from the Downloads section is not part of the repository, so git will not download it automatically. You'd need a custom script to do that.
  2. git pull will download changes and merge; git fetch will download change sets
  3. gitk for the history and git gui for commands. They can be accessed from each other.
  4. take a look at this answer for Nautilus integration.
0
0

Here is "a script to check for updates on git repository to download files"

zenity --info title="Check git updates" --text="\n<big><b>Greybird:</b></big> $(cd "$HOME/.local/share/git/Greybird" && git pull)\n"

You simply need to customize this with your git repo(s) and its/their location(s), adding others if required.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .