Coder Social home page Coder Social logo

sgit's Introduction

A Git client for Android.

This project is no longer being maintained. Further development on this app is now being done in the MGit project. Please submit all PRs and issues there.

Notes

Join the chat at https://gitter.im/sheimi/SGit

Build Status

  • All repositories are stored in [sdcard dir]/Android/data/me.sheimi.sgit/files/[repo name]. If you want to delete this app, you can manually backup repositories from this location.
  • The GitHub repo of this project is: sheimi/SGit.
  • If you encounter any issues (bugs, crashes, etc.) and want to help improve this project, please open an issue on GitHub describing: what the issues are; and how they were caused, to allow for re-creation and fixing of bugs.
  • This app is for Android v4.x. It might work on Android v2.x, but will not be supported officially due to lack of resources for testing.

Supported Features

  • Create local repositories
  • Clone remote repositories
  • Pull from origin
  • Delete local repositories
  • Browse files
  • Browse commit messages (short)
  • Checkout branches and tags
  • HTTP/HTTPS/SSH are supported (without private key passphrase)
  • Username/Password authentication is supported
  • Search local repositories
  • Private keys management
  • Manually choose code language
  • git diff between commits (to be enhanced)
  • Import copied repositories (that is, you can copy a repository from computer and import to SGit)
  • Checkout remote branches
  • Merge branches
  • Push merged content
  • Edit file (you must have some app that can edit file)
  • Commit and push changed files (commit all changes)
  • Committer information
  • Prompt for password
  • Choose not to save password and username (will not be saved in disk but may be temporarily saved in memory)
  • git status
  • Cancel when cloning
  • Add modified file to stage
  • git rebase
  • git cherrypick
  • git checkout <file> (reset changes of a file)

Android app on Google Play Android app on F-Droid

Quick start

Clone a remote repository

  1. Click on the + icon to add a new repository.
  2. Enter remote URL (see URL format below).
  3. Enter local repository name - note that this is not a path since SGit stores all repositories in the same directory on the mobile device.
  4. Username - username to use to clone the remote repo.
  5. Password - password to use to clone the remote repo.
  6. Click the Clone button.
  7. If all the credentials are correct, SGit will download the repository (all branches) to your device.

Create a local repository

  1. Click on the + icon to add a new repository.
  2. Click on Init Local to create a local repository.
  3. Enter the name for this repository when prompted.
  4. A local repo will be created.

URL format

SSH URLs

  • SSH running on standard port (22): ssh://username@server_name/path/to/repo
  • SSH running on non-standard port: ssh://username@server_name:port/path/to/repo
  • username is needed - by default, SGit tries to connect as root.

HTTP(S) URLs

  • HTTP(S) URL: https://server_name/path/to/repo

To Do List

  • Private key passphrase
  • Submodule support
  • Dark theme
  • Commits related to a file
  • Commit graph (low priority)

License

GPLv3

Help

If you want to help improve this project, contributions are very welcome.

Fork from this repo: sheimi/SGit, create a new branch, commit your changes and then send a pull request against the master branch of this repo.

sgit's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sgit's Issues

Custom storage location of downloaded repositories

Basically, a setting that allows you to specify where you want the repos to go when they are downloaded, as opposed to just dumping them into /sdcard/Android/data/me.sheimi.sgit

Defaulting to there is fine, however.

Additionally, have an option when changing the download location to move the repos from their previous location to the new one, so they aren't lost somewhere, and so you don't have to redownload them.

Rename local repository

I've local repository with '.git' and some without...
I also want to rename repos to change case.

Stores imported private keys in public world writable location.

Private keys are imported and saved to Android/data/me.sheimi.sgit/files/ssh/ at the getExternalFilesDir(). This location is world readable and writable by every application with access to the shared public storage area.

While being able to backup/restore keys and repositories through that directory structure may be useful, it is generally a BAD idea to say, allow any app with network and /sdcard access to go upload this file or edit it at will. In fact this is exactly why the very popular OpenSSH client program used on PCs refuses to use key files that are world writable or with permissions to loose. SGit has none of this user-protection.

Such sensitive files belong in the SGit applications private directory structure under /data/data/me.sheimi.sgit. Instead of using FsUtils.getDir(), SGitSessionFactory should be using some sort of FsUtils.getPrivateDir() method.

Create new local branch

Perhaps I have simply missed how to create a local branch but it appears to me that currently it is only supported to checkout already existing branches. For me to actually be able to use this in a sensible way, I would need to create local branches. I believe it is a rather integral component in a git work flow.

Sometimes files won't open

Every now and then when I try to view an file, the loading indicator just keeps spinning and does not open the file in question. If I however open this file in DroidEdit and then return it opens fine for some reason.

Include darker theme option

Honestly, the blue theme is really pretty and all, but sometimes I don't like having my eyes scorched.

A darker or black theme would be nice.

Crashes on launch since last update N7

Looks like it's not resolving the sherlock actionbar library. I sent a full report via the Google crash log. Let me know if you want more information.

SGit is awesome

Just wanted say thanks for this awesome app SGit has become my goto android .git app while mobile keep up the great work buddy and Happy Holidays sheimi ;)

Can't clone repos

At the moment I can't clone any repo on github. The command fails via ssh and https with "exception caught during execution of fetch command".

Regards
Stephan

Feature Add multiline comment.

When I wrote my commit message I often use carrier return for each idea a line.
Maybe it will be great to enable multiline comment.

Allow choosing files to be committed/respect .gitignore

Currently every time I hit commit SGit commits everything in my working tree, and automatically adds new files to the git repository. I'd like to be able to control this. For example: compiling tex documents generate a lot of by-products that are useful locally but not in the repo.

One way could be to respect and use .gitignore.

Unicode encoded files (with BOM)

If there is a Unicode encoded file inside the repository using a BOM, the BOM seems to be displayed as a red dot as the first character of the file....
... the Encoding of the files themselves seems to be ok. Even editing seems to work.

You probably want to change that behaviour.

Markdown: Support fenced code

Currently the markdown syntax doesn't seem to support 'fenced' code blocks (i.e. those delimited by triple back tick (```).

So, the following would not be properly recognised as code:

1.  Initilize git **bare**:
    ```
    mkdir dir.git
    cd dir.git
    git --bare init
    ```
2.  Enable and configure sparse-checkout:

It would be great if that could be fixed!

"invalid privatekey" error when interfacing with gitosis

This is probably an error in my configuration of Gitosis, but the error message rendered by SGit makes it very difficult to track down. I'm trying to connect to a repository hosted via gitosis. I've imported a private key into SGit and committed the corresponding public key to Gitosis, but when I attempt to connect, SGit gives me an "invalid privatekey" error. (It also wipes out all of the information I entered about the repository, requiring me to painstakingly type it all back in to try again.)

Can you tell me whether this error means that the host rejected the private key, or whether SGit has determined the key is invalid? Thanks.

Can't add repos

It says 'Invalid remote' when I try to add a repo.
Even this one won't work. Am I doing something wrong?

no way to edit connection

It would be great to be able to edit connection info after a repo has been cloned, or in other way to edit the .git/config file. (in my case I use to switch between my lan hostname and the associated wan hostname for the same repository server)

Bug can't push to origin

When I try to push to origin
I see "opening connection" 0% and 0/0
And it's disappear after 2 or 3 seconds.

Because my repos wasn't up to date so it's freeze at this time.

Maybe you have to add a message to update the repos before pushing.

no way to see log info

When I make a pull request on a given repository, I encounter a "pull failed" error but without additional info I can't know what to do.

Show Diff for commit on Commits tab

Wouldn't it make more sense to propose to see the diff of the commit rather than to checkout to it?
2014-01-04-00-47-04

For checking out the user could long press then get the option. On my mobile phone, i'm more concerned about seeing what my mates have done rather than checkout. I guess the diff command is run more than checkout in most cases.

http.sslVerify = false not supported in repo's config?

Adding http.sslVerify = false to [sdcard dir]/Android/data/me.sheimi.sgit/files/repo/myrepo/.git/config causes the app to crash on opening the repo.

I manually imported a repo whose remote is an https URL, self-signed cert.

No error message if push is rejected by remote

If you attempt to push to a remote, and the push is rejected by the remote (such as, if the branch you are pushing has diverged on the remote, or if you are pushing to a "non-bare" repo, and the branch you are pushing is currently checked out on the remote), the user receives no indication that the push is rejected - it will appear that the push has succeeded, but when you look at the remote, you can see that the commits you pushed are not there.

File editing

Hello!

Could you please fix the file editing feature, because if I click on a file, the coming loading screen never ends.
I'm using Android 4.1.3 (I think) and sasung Galaxy S2 and WLan 16.000 kb/s

Bug line number

If you create a new file and you open it line number begin by "1." on the first line and "0." on second line.

[FEATURE] Implement an package explorer?

It would be nice if there was an package explorer available to make it easier to switch to files and open these in e.g. DroidEdit. Not as much as an real issue but more a feature request :-)

No way to cancel a git operation

SGit on my phone is stuck in a state it's trying to resolve deltas for 3 days. I think it would be useful to permit the cancellation of the sgit action in progress when a long click is made on a repository item.

Thanks !

Initialize empty git repo locally

I'm probably in the minority, but I like to use git for everything. School projects, code, you name it. The ability to create totally local repositories would be handy.

Having access to the git add remote command would be nice after this is added, in case the user decides to make it remote later on.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.