Coder Social home page Coder Social logo

bilelmoussaoui / nautilus-git Goto Github PK

View Code? Open in Web Editor NEW
147.0 147.0 9.0 276 KB

Nautilus/Nemo extension to add important information about the current git directory

License: GNU General Public License v3.0

Python 94.66% Meson 5.34%
extension git nautilus nautilus-extension nemo nemo-extension

nautilus-git's People

Contributors

bilelmoussaoui avatar fbruetting avatar fitojb avatar hobbypunk90 avatar tingping avatar

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

nautilus-git's Issues

Build prefix

• Isn't it possible to work with regular build prefix "/usr/local/"? I tried and it sadly didn't work.
• If it's required to specify the "/usr" prefix, could you add this please to the Meson config? Otherwise people just run meson .. and wonder why it doesn't work… until they read the README file.

HiDPI scaling

Here's a screenshot on my UHD screen, would you correct the icon scaling please? (But I must admit, that Fedora has several UI bugs recently, so I'm not sure if this is due to Fedora or your program).

bildschirmfoto vom 2017-02-11 20-15-17

Performance issues with large repositories

Cool extension but had to uninstall it for now as it really struggles to handle large repositories like Chromium. Nautilus freezes and the whole system crawls until it's force closed. Hope it will be fixed soon

Off topic - Could you please tell me the names of the theme and icon pack in the screenshots?

ninja install failing (msgfmt ITS rules issue)

Hi,

I am on openSUSE Tumbleweed, so I am installing from source.

It fails on:

% sudo ninja -C builddir install                      
ninja: Entering directory `builddir'
[1/2] 'Generating nautilus-git.metainfo.xml_merge with a custom command.'
FAILED: data/nautilus-git.metainfo.xml 
'msgfmt' '--xml' '--template' '../data/nautilus-git.metainfo.xml.in' '-d' '../data/../po' '-o' 'data/nautilus-git.metainfo.xml'
msgfmt: Impossible de localiser les règles ITS pour ../data/nautilus-git.metainfo.xml.in
ninja: build stopped: subcommand failed.

The message is cryptic to me, sorry.

python3 support

Support for Python3 would be nice at some point (https://pythonclock.org/). I don't know about other distributions, but at least on Arch Linux you can chose between python2-nautilus or python-nautilus for the Python bindings.

A quick test on my Arch Linux system showed that 2to3 creates a version of the current master that works just like that with python-nautilus. I am sure you can make the code 2 and 3 compatible at the same time, but that usually requires a little extra work. I can help out with a PR if needed.

Strange output when opening "other locations" in Nautilus

Number of files is 0
Number of files is 0
Number of files is 0
Number of files is 0
Number of files is 0
Number of files is 0
Traceback (most recent call last):
  File "/usr/share/nautilus-python/extensions/git.py", line 417, in get_widget
    if is_git(uri):
  File "/usr/share/nautilus-python/extensions/git.py", line 62, in is_git
    output = execute('git rev-parse --is-inside-work-tree', folder_path).lower()
  File "/usr/share/nautilus-python/extensions/git.py", line 80, in execute
    stderr=PIPE, cwd=working_dir)
  File "/usr/lib64/python2.7/subprocess.py", line 390, in __init__
    errread, errwrite)
  File "/usr/lib64/python2.7/subprocess.py", line 1024, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory: 'ocations:///'

Question: how do I get compare (diff) window?

I've istalled from AUR nautilus-ext-git,
The extension works fine and shows me the changed files list when I click on the pencil icon on top yellow bar. However if I select one of the files from the popup menu, nothing happens (I expect to have the compare window like the second screenshot in the README.md file).

Do I miss any (optional) dependency?
Thanks!

More button and Branch switching missing?

I have this setup with a bitbucket repo, and have "Open remote URL in a browser", but I do not have compare commits, or any way to switch branches like in screenshots?

No items

No items. Streaked on the screenshot. How to activate them?

https://i.imgur.com/ruuT6tD.jpg

nautilus 3.30
python2-nautilus 1.2.2-3
nautilus-git 1.3-1
git version 2.21.0

Unable to Build - List of languages empty.

Hi,

While building, I am facing the following error. Can you suggest how to fix it ?

➜ build git:(master) meson .. --prefix /usr
The Meson build system
Version: 0.34.0
Source dir: /home/mac/nautilus-git
Build dir: /home/mac/nautilus-git/build
Build type: native build
Build machine cpu family: x86_64
Build machine cpu: x86_64
Project name: nautilus-git
Native c compiler: cc (gcc 6.2.0-5ubuntu12)
Program python2 found: YES (/usr/bin/python2)
Program intltool-merge found: YES (/usr/bin/intltool-merge)
Message: Looking for dependencies
Program python2 found: YES (/usr/bin/python2)
Found pkg-config: /usr/bin/pkg-config (0.29.1)
Native dependency glib-2.0 found: YES 2.50.2
Native dependency gobject-2.0 found: YES 2.50.2
Native dependency gobject-introspection-1.0 found: YES 1.50.0
Native dependency gtk+-3.0 found: YES 3.20.9
Message: DESTINATION DIR : /usr
Message: Update translations

Meson encountered an error in file po/meson.build, line 10, column 5:
List of languages empty.

Code cleaning

The code, for now, is a mess. Too much-repeated stuff. Need some refactoring

Git information not displayed

Hi I just installed extension but nothing is shown in directories with git repository. I have Ubuntu 14.04 and Nautilus 3.10.1.

Shell trace:

Traceback (most recent call last):
  File "/usr/share/nautilus-python/extensions/git.py", line 531, in get_widget
   widget = NautilusLocation(git, self.window)
  File "/usr/share/nautilus-python/extensions/git.py", line 243, in __init__
    self._build_widgets()
  File "/usr/share/nautilus-python/extensions/git.py", line 273, in _build_widgets
    self._generate_popover(button)
  File "/usr/share/nautilus-python/extensions/git.py", line 314, in _generate_popover
    self._popover = Gtk.Popover()
  File "/usr/lib/python2.7/dist-packages/gi/module.py", line 320, in __getattr__
    return getattr(self._introspection_module, name)
  File "/usr/lib/python2.7/dist-packages/gi/module.py", line 139, in __getattr__
    self.__name__, name))
AttributeError: 'gi.repository.Gtk' object has no attribute 'Popover'

how does "compare commits" works on?

After ninja install and restart nautilus, a blue bar shown in git directory.

But the bar never change color or status, even I change some files or comit in CLI or push. press F5(refresh) does not work. So how does it works.

BTW: only master branch here. Fedora 29 here.

Fedora COPR package is broken

At least with Fedora 25, I have not tried other versions. It also does not appropriately declare nautilus-python a dependency. Even after installing this it does not work however.

Choose Branch Menu Always in center of screen.

OS: Arch Linux
Installed From: AUR
nautilus-git version: 1.2

When I click the current branch GtkButton that opens the window to switch the branch, it is always at the center of the screen.
screenshot from 2017-05-29 17-55-59

The correct behaviour would be for the window to appear in the center of the NautilusWindow.

Instant reaction to checkouts

Would you make this respond to checkouts directly without having to manually reload the folder? That'd be perfect!

Paste git repo url to clone

How it should work?

  1. User copies an URL that matches:
  • https://github.com/<user name>/<repo name>
  • http(s)://*.git
  • git://*
  • git@...
  1. User opens Nautilus and pastes (either by Ctrl + V or by right-click context menu)

  2. A dialog appears and asks user to name target directory (default to repo name)

Support Nemo file manager

Hi,
First of all, thanks a lot for this great extension and I find it really useful and must to have. I use Linux Mint so converted your extension to Nemo. Just replacing all the Nautilus to Nemo in the git.py did the magic. According to my preliminary testings, it seems to work without any issues in Linux Mint 18.1 with Nemo 3.2.2.
Do you have any idea to support Nemo? If so, I will send a PR to whatever the branch or new repository you prefer.

Thanks again.

Create an appdata file

I think i should implement an appdata file just in case Gnome Software supports Nautilus extensions in the future!

side-by-side diff view

Would be great to have a side-by-side view for diffs, as that format is easier to read than the unified format.

Theming support

Big sorry for flooding, but as you see in the screenshots, the Adapta theme highlights all additional appearing top bars in nautilus yellow, but not your top bar. I don't know if it'll be appropriate for your script, and I even don't really know how this works internally, but if you want to have theming support, I think you need to implement those hintings.

bildschirmfoto vom 2017-02-11 20-21-25

bildschirmfoto vom 2017-02-11 20-29-40

Port to gtk4

Hello,

Carlos from Nautilus team here. We are porting Nautilus to gtk4 for 3.30 (or 3.32 depending on our discussions with extension devs). We were wondering if would be possible for this extension to be ported to gtk4 too and what's the overall status of the extension.

Let me know if you have any question. Also feel free to reach me over #nautilus at irc.gnome.org as csoriano.

Cheers

ModuleNotFoundError: No module named 'urlparse'

I found that this extension does not work correctly in my local,
It seems that either I dont have the right python version, or a missing module? But I did not find any requirements file :S
Any clue?

➜  mangata-e2e git:(feature/benchmarking-A) ✗ nautilus ./       
Traceback (most recent call last):
  File "/usr/share/nautilus-python/extensions/nautilus-git.py", line 39, in <module>
    from utils import is_git
  File "/usr/share/nautilus-git/src/utils.py", line 22, in <module>
    from urlparse import urlsplit
ModuleNotFoundError: No module named 'urlparse'
less /usr/share/nautilus-git/src/utils.py

I tried with both versions of python

mangata-e2e git:(feature/benchmarking-A) ✗ python --version
Python 3.10.3

and

➜  mangata-node git:(feature/use-mangata-registrator) python --version
Python 2.7.18

Thanks!

Pull

A pull button to get the latest changes from origin would be very useful. Bonus points if I can --rebase.

Fedora 30 with copr

Hi,
When I run:

dnf copr enable -y heikoada/nautilus-git
dnf install nautilus-git
nautilus -q 

I get this error:

Traceback (most recent call last):
  File "/usr/share/nautilus-python/extensions/nautilus-git.py", line 39, in <module>
    from utils import is_git
  File "/usr/share/nautilus-git/src/utils.py", line 22, in <module>
    from urlparse import urlsplit
ModuleNotFoundError: No module named 'urlparse'

I tried to install the urllib / urlparse package in pip2/pip3 but I can't find them

Folder badges

RabbitVCS Nautilus integration has the nice feature of adding badges to folders under version control. The badge icon also shows the status of the clone. Dropbox does a similar thing to show a folder is under dropbox management and the badge icon tells you the synchronization state.

It would be great if this could be implemented for nautilus-git. Perhaps with color/icon coding like:

  • red = uncommitted modifications
  • orange = unpushed commits
  • yellow = branch is behind on origin, and can be fast-forwarded
  • green = clean

Get rid of git

For now, i use git in order to get every information needed. Which is not perfect as i've to always parse the output in order to get the right information that i want to use.

Implementing a simple git-python library would be great. Shouldn't do too much:

  • init (will add a shortcut to init a new repository in the future)
  • status (used to in diff view & the counter of added/modified/removed files)

Possible ideas(not in the near future):

  • Add files to staging area
  • Commits
  • List of commits btw HEAD & origin

Error where there are space or ' char in the folder name

Hi I just found a bug : There is nothing displayed when there is a space or ' in the path

Shell trace :

Traceback (most recent call last):
  File "/usr/share/nautilus-python/extensions/git.py", line 60, in get_widget
    if utils.is_git(uri):
  File "/usr/share/nautilus-git/src/utils.py", line 38, in is_git
    folder_path).lower()
  File "/usr/share/nautilus-git/src/utils.py", line 59, in execute
    stderr=PIPE, cwd=working_dir)
  File "/usr/lib/python2.7/subprocess.py", line 390, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1024, in _execute_child
    raise child_exception
OSError: [Errno 2] Aucun fichier ou dossier de ce type: "/home/skad/Herdelia's%20Legacy"
('Handling file: ', "file:///home/skad/Herdelia's%20Legacy/Rex%20Parallel")
('file scheme: ', 'file')
Traceback (most recent call last):
  File "/usr/share/nautilus-python/extensions/git.py", line 60, in get_widget
    if utils.is_git(uri):
  File "/usr/share/nautilus-git/src/utils.py", line 38, in is_git
    folder_path).lower()
  File "/usr/share/nautilus-git/src/utils.py", line 59, in execute
    stderr=PIPE, cwd=working_dir)
  File "/usr/lib/python2.7/subprocess.py", line 390, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1024, in _execute_child
    raise child_exception
OSError: [Errno 2] Aucun fichier ou dossier de ce type: "/home/skad/Herdelia's%20Legacy/Rex%20Parallel"

Git info bar is higher than other nautilus info bars

Hi there,
Thanks for this cool nautilus extension. On my system the git bar is slightly higher than other nautilus bars. Would be cool if the height would be somewhat less to match the other info bars. See screenshot for what I mean.
screenshot from 2017-04-22 16-30-06

Regards,
jens

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.