LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > General
User Name
Password
General This forum is for non-technical general discussion which can include both Linux and non-Linux topics. Have fun!

Notices


Reply
  Search this Thread
Old 11-18-2023, 11:07 PM   #1
Xeratul
Senior Member
 
Registered: Jun 2006
Location: UNIX
Distribution: FreeBSD
Posts: 2,618

Rep: Reputation: 255Reputation: 255Reputation: 255
How to list files on GIT ?


hello,

How to list files on GIT ? Example, git to the server with the project, and type ls.
A bit like FTP.

Code:
ncftp ftp.gnu.org 
ls
On GIT?

Kind regardss
 
Old 11-22-2023, 01:17 AM   #2
des_a
Senior Member
 
Registered: Sep 2006
Posts: 1,241
Blog Entries: 43

Rep: Reputation: 30
I'm not as familiar with the command line for git, but here's what I would do, knowing what I know.

I would first do:

Code:
git clone <repository>
Then, go into the local directory where you cloned it, and ls there. If you want to do it by command line, that's what I would do. You could also get github desktop, and use that.
 
Old 11-26-2023, 01:01 AM   #3
des_a
Senior Member
 
Registered: Sep 2006
Posts: 1,241
Blog Entries: 43

Rep: Reputation: 30
Did that solve the problem?
 
Old Yesterday, 05:48 PM   #4
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,409
Blog Entries: 4

Rep: Reputation: 3836Reputation: 3836Reputation: 3836Reputation: 3836Reputation: 3836Reputation: 3836Reputation: 3836Reputation: 3836Reputation: 3836Reputation: 3836Reputation: 3836
Try git ls-tree and git ls-files.

If you prefer not to "ride the pony bareback," there are also a number of really-good GUI tools for every operating system. I find them very convenient when I want to "browse" a repository.
 
Old Today, 09:03 AM   #5
GazL
LQ Veteran
 
Registered: May 2008
Posts: 6,756

Rep: Reputation: 4872Reputation: 4872Reputation: 4872Reputation: 4872Reputation: 4872Reputation: 4872Reputation: 4872Reputation: 4872Reputation: 4872Reputation: 4872Reputation: 4872
Quote:
Originally Posted by sundialsvcs View Post
Try git ls-tree and git ls-files.

If you prefer not to "ride the pony bareback," there are also a number of really-good GUI tools for every operating system. I find them very convenient when I want to "browse" a repository.
I got the feeling based on the fact that he mentioned ftp that he wants to be able to query files in a remote repo. ls-tree will require at least a 'fetch' and ls-files works on a checked out working directory/index.

Short answer to the question is that git's interactions with remote repositories are very limited. It isn't a file-server and one shouldn't try and treat it as such.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: How to Use the Git Tag Command to List and Sort Git Tags LXer Syndicated Linux News 0 12-16-2021 08:30 PM
[SOLVED] git bisect not reporting updated files like git checkout. Manual checkout same. ballsystemlord Linux - Software 3 04-13-2021 01:33 AM
LXer: Gitpod git-bolts git-IDE onto GitHub for in-browser code git-editing LXer Syndicated Linux News 0 09-05-2018 05:50 AM
[SOLVED] Can't install Git repo (I don't git git ) Nemus Linux - Software 3 05-20-2011 03:09 PM
inconsistency issue of git-clone ***/git/mesa/drm with the existing kernel source centguy Linux - Desktop 2 10-08-2008 11:36 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > General

All times are GMT -5. The time now is 10:18 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration