Hacker News new | past | comments | ask | show | jobs | submit login
GitQlient – a multi-platform GUI-oriented Git client written with Qt (francescmm.github.io)
170 points by app4soft on April 27, 2020 | hide | past | favorite | 64 comments



Is anyone aware of a publicly available code base to look into when searching for high quality Qt-based (desktop) applications? Think chromium-quality software quality code base. I am looking for inspiring patterns and also things such as naming schemes as I regularly change my mind when it comes to developing Qt based applications with regard to:

  - naming things (e.g. should signals/slots be prefixed (sigFoo() -> onFooBared())
  - how to deal with signal functions actually not implemented (clang-tidy warnings)
  - how to break up large main window classes in a reasonable manner
and so on. Typically I immerse myself in one of the larger code bases I'm aware of (Android, Firefox, Chromium, Tensorflow, and some others) and regularly discover pretty useful patterns I can make use of. However, I was unlucky to find something for Qt based.


You could look at KDE, I don't know about the quality but it's a big enough public effort that it should be well reviewed. https://en.wikipedia.org/wiki/KDE_Projects


> Think chromium-quality software quality [...]

There's an irony somewhere in there that Chromium is a descendant of KHTML, KDE's rendering engine, which became WebKit and was originally written using Qt. And Google and Apple's contributions were regularly derided for being relatively low quality.

Qt and KDE have always had a lot of cross-contribution, so KDE (its libraries, for example) is a good place to start:

https://github.com/KDE/kdelibs

There's also this old, but still relevant, article on designing Qt-style APIs (which had a big impact on me personally):

https://doc.qt.io/archives/qq/qq13-apis.html


The KDE applications would seem like a good place to start.

https://kde.org/applications/office


Qt itself, like for example https://github.com/qt/qttools?


Good suggestion. Code snippets showing the naming style they use:

    connect(contextShortcut, SIGNAL(activated()), this, SLOT(showContextDock()));

    connect(m_messageView->selectionModel(),
        SIGNAL(currentColumnChanged(QModelIndex,QModelIndex)),
        SLOT(updateLatestModel(QModelIndex)));
Taken from https://github.com/qt/qttools/blob/7ec161d6f/src/linguist/li...


qBittorret has always been a bit cutting edge with Qt feature usage, which can be interesting.

https://github.com/qbittorrent/qBittorrent

not able to comment on code quality.


QGIS could be interesting. It contains tons of functionality, and interfaces with multiple other geospatial projects.


QtCreator maybe?


seconded, I used the general design ideas of QtCreator as a baseline for my own stuff and it's been great


Virtualbox maybe


Nice, good job, specially for going with Qt instead of Electron.


EVen thought I understand the bashing Electron gets, it doesn't seem that Qt is the right choice right now.

I tried to test the software: Needed Qt as there are no releases, but Qt is behind a paywall, and according to a previous post here in HN [1] it seems they resorted back to tactics they already reckoned (In 2015) were not good. I guess I'll just have to wait until the page has the releases ready.

[1] https://news.ycombinator.com/item?id=22821050


> I tried to test the software: Needed Qt as there are no releases

This is not true!

There are releases, and especially for Linux it already packaged as AppImage (portable package).[0]

[0] https://github.com/francescmm/GitQlient/releases


> but Qt is behind a paywall,

apt install qtbase5-dev / brew install qt / whatever works just fine here.

if you are on windows and absolutely want the official releases :

    pip install aqtinstall
    python -m aqt install 5.14.2 windows desktop win64_msvc2017_64 -O c:/Qt/


Cheers.

I'm on debian 10 and that didn't work, but I suspect it's something to do with my current installation that complains about a missing Qt4 software even after installing that (That I'll research when I have the time).


Likely.

    sudo docker run -it debian:10
    apt update
    apt install qtbase5-dev build-essential g++-8 qt5-qmake qt5-default git
    git clone --recursive -j16 https://github.com/francescmm/GitQlient
    mkdir build && cd build
    qmake ../GitQlient && make -j16
seems to produce a build without errors here


Qt isn't behind a paywall, but they do their best to hide the open-source installers.

https://www.qt.io/offline-installers


FOSS religion is not relevant for everyone.

Second creating an account at Qt doesn't hurt.

Finally, they need to pay their bills, just like I have to.


We all have to pay bills but Microsoft is giving away so much stuff that Qt approach is hurting them.

If I have to just make an application in .NET env as a small time dev I don't even have to register anywhere just get .net core and VS Code.

OK I understand that MS can pull it off because they have big companies paying for their stuff. I also don't really know how to compete with them. But me as a small time dev cannot afford to get with all Qt BS where there is almost no BS for using free stuff from MS. (I have to count every minute or hour, so putting up with some forms or else is taking too much of my time already)

I would love to give money to Qt instead of MS or Apple but yeah I have to pay my bills as well.


This probably the less mobile friendly website I've seen in a while! I'll have to check it in my laptop later on.


I'm going to check that right now. It's not finished yet but a User Manual should look bad. :)


I had trouble even on a laptop screen!


Unfortunately it's not quite as as good as it could be on a 1928x1080 desktop monitor either. I had to zoom to 170% to make it comfortable to read (my eyesight is not great, but not terrible either). And that introduced horizontal scrolling. So I had to drop back down to 150% zoom.


I don't know what you talking about, because I has no any issues on laptop.[0]

BTW, Alternatively try read docs directly from repo on GitHub.[1]

[0] https://i.imgur.com/9wGBlLJ.png

[1] https://github.com/francescmm/GitQlient/blob/master/docs/ind...


- text straight-up cuts off: https://imgur.com/uYCAxbk

- very weird layout: https://imgur.com/3uFfmSW

- mobile users may not even see content if they don't scroll left / right after scrolling down a bit: https://imgur.com/UQrKtcy


Looks really close to Sublime Merge[1], which is great.

1: https://www.sublimemerge.com/


After seeing quite a few new Git clients, Sublime Merge is still, imho, the easiest to use


i find magit even better, but of the non-emacs gits porcelains, smerge is way at the top of the heap.


This looks amazing! Looks almost as slick as GitKraken, without requiring all of my RAM+1GB to run.

Great work! I'll be recommending this to anyone who is looking for a git GUI client.


JFTR, Also take a look on Guitar[0] - another Qt-based Git GUI client.

I actually use Guitar, but GitQlient is also installed on my PC.

[0] https://github.com/soramimi/Guitar


What does GitQlient do that Guitar, QGit, CodeReview, GitAhead, or git-cola do not?


I can open multiple repositories at the same time in the same screen. I actually forked from QGit becuase I was missing a lot of functionality and inactivity in the UI.

I couldn't find a way to do that in QGit and GitAhead at least. I didn't try the others.


This looks cool. I'm curious if people use Git's tree view, in any form, as part of the regular workflow? If so, how? I have never found it useful, intuitive, or usually readable / parsable. Not the graph drawn on the command line, certainly not Github's tree view GUI of forked projects. I've also only ever worked on a project with one or two main trunk branches (master, and maybe dev), and feature branches, and very little merging between other arbitrary branches.


At work, we use feature branching extensively, and there's often somewhere between 3 and 6 active feature branches at any time. The graph view is a good way to keep track of what's going on overall, if you're watching it regularly and branch parents are within a screen or two).

Just earlier today I was working on testing a new feature that depended on 3 other independent fixes (basically, bugs found while I was building the feature). I did the fixes each as an independent branch, so I could get them in faster (before my new feature is done) plus to make the code review easier. The tree view is invaluable in testing my new feature to be sure I've merged the right fixes and am doing changes in the right branches.

I also use it very occasionally to isolate if and/or why a particular fix got into a specific release branch (or not). I think there's probably better ways to do this (eg using bisect) but I do it so rarely I haven't bothered to learn.


I use it frequently. I work mostly solo but am often force to jump around quite a bit. So I use a variation of GitLab Flow[1] and often have dozens of active feature branches going on. It's useful seeing where a branch was created against develop so I can have some idea of what's been done on that branch since I last worked on the branch I just switched to, and what to expect when I merge or rebase.

[1]: https://docs.gitlab.com/ee/topics/gitlab_flow.html


I use it as part of my daily flow.

One example: I work on a feature, which necessitates some refactoring, maybe upgrading a dependency, and oh, while I'm in the middle of it I notice some other, unrelated things, that need changing. In order to not have to break my flow and think too much about which changes are required for what, I just commit it all on the same local branch.

This then gets broken up into different branches in individual PRs.


I don't understand what this has to do with a visual view of branches and merges


It certainly helps me when splitting, comparing and picking changes between branches. Also to keep track of how upstreams have changed compared to my working branch before doing rebases.

Oh, and re Githubs fork view (which could be improved on the UI side), is helpful when seeing if anyone else has picked up the ball on unmaintained repos.

If you don't find it useful, fine, I don't think we all need to grok each others personal workflows and motivate them to each other?

Maybe you can compare it to a visual file manager that visualizes your directory structure as a tree; some people find it a necessity to get an overview of their file system, some don't.


Onestly, I always found all git interfaces (gui or text based) from just ugly and useless to totally counterintuitive.

With one exception: the only good git ui that I tolerate for its clearance is the eclipse egit plugin

https://www.eclipse.org/egit/


If you mean the history graph, try gitk (part of the git distribution, but you may need to install a separate git-x11 or similar package).


Tried this on win10: it seems to crash without an error message when I try and open a repository.


As @app4soft said, please open an issue and attach as many logs you can: https://github.com/francescmm/GitQlient/issues

To be fair, in windows the performance is quite low due to Git Bash performance as well. I need to improve that :)


Please, report bugs to developer.[0]

[0] https://github.com/francescmm/GitQlient/issues


The tree looks nice. Similar to gitk, sourcetree or bitbucket. For whatever reason, github and gitlab cannot manage to get a similiar clean vertical git tree view.


Can this stage individual lines, and then display a view of only staged lines and no un-staged lines? AKA only the things you are about to commit.

In SourceTree this is called "split view staging" and I find it indispensable. But SourceTree is so old as slow and unsupported that I'm desperately trying to find an alternative. Most of the existing GUI clients don't have this option.


SublimeMerge[1] allows staging only chunks of files.

[1]: https://www.sublimemerge.com/


You can also select lines in the chunks of the file to stage individual lines.

Not super discoverable but pretty useful.


> Can this stage individual lines, and then display a view of only staged lines and no un-staged lines?

Try ask developer or submit feature request.[0]

[0] https://github.com/francescmm/GitQlient/issues


It's something planned for the future :)


I use gitg, precisely because it has this feature.

https://github.com/GNOME/gitg


The link's layout is broken on mobile.


It certainly looks quite beautiful, but sadly UI interactions -- resizing, clicking around, etc. -- seem to be fairly laggy at this point. Love the look-and-feel, but I think the interactive performance is frustrating at this point.


Hi! Thanks for the feedback!

Which platform did you try it in? I'd love to have as much info as possible so I can fix it :)


This is on Windows 10 x64. I'm interested to try again when you have a new build.


There's also gitg which is fairly fast https://wiki.gnome.org/action/show/Apps/Gitg


Kinda looks like GitAhead, but I'll be sure to give this one a shot.

https://gitahead.github.io/gitahead.com/


Great job on using QT!!


It is awful how all git gui clients completely ignore git submodules


How would I get this to run on MacOS?


Should be able to download the .app release from here https://github.com/francescmm/GitQlient/blob/master/docs/ind....

Looks to be build instructions as well in appendix b on the same page.


Sadly, if you follow the link to the releases section, there is no release for macOS.


You can install Qt with HomeBrew, and then building (I did it) is just:

  $ qmake && make
Then you'll get a GitQlient.app.


There are no releases for the software yet, so you need Qt in order to compile it. Check out the "Build" section on the page.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: