Most active commenters
  • bisby(6)
  • Suppafly(5)
  • (4)
  • koen31(3)

←back to thread

Grayjay Desktop App

(grayjay.app)
510 points pierrelf | 55 comments | | HN request time: 1.986s | source | bottom
1. bisby ◴[] No.42474981[source]
Launching the Linux release and noticed in the logs:

Directories:User Directory: /home/bisby/Grayjay

And there is a directory there now. I absolutely hate having stuff automatically create anything in my home directory like this. Ideally, this should be following XDG directory guidelines on linux: https://specifications.freedesktop.org/basedir-spec/latest/

replies(4): >>42475304 #>>42479118 #>>42482018 #>>42483636 #
2. koen31 ◴[] No.42475304[source]
Grayjay dev here. If you want it to use your user directory like other apps, just remove the file called "Portable". Keep in mind that it just uses your working directory to write files otherwise.
replies(7): >>42475423 #>>42475680 #>>42475733 #>>42475939 #>>42475958 #>>42476022 #>>42476313 #
3. godDLL ◴[] No.42475423[source]
That's a windows-ism, we don't like that kind of stuff. Not on any other OS we don't.
replies(2): >>42475609 #>>42475916 #
4. freedomben ◴[] No.42475609{3}[source]
Parent is not wrong, but definitely could have some improved manners and tact.

As a linux user I wanted to make sure to say thank you for supporting and thinking about linux!

replies(3): >>42475919 #>>42476531 #>>42477625 #
5. SpaghettiCthulu ◴[] No.42475680[source]
You should be using `~/.local/share`, `~/.config`, and other standard directories on Unix systems. macOS has its own conventions.
replies(1): >>42475742 #
6. Lariscus ◴[] No.42475733[source]
Is a Flatpak release planned? I am interested in Grayjay but don't really want to deal with a binary that lives outside of my distros package manager.
7. zamalek ◴[] No.42475742{3}[source]
You shouldn't even use those, at least hardcoded. Follow the XDG Base Directories spec: https://specifications.freedesktop.org/basedir-spec/latest/
replies(1): >>42476133 #
8. indrora ◴[] No.42475916{3}[source]
Even Windows has %appdata% which is where you put stuff on disk that you need to stash away. There's also function calls iirc which will give you a handle to a temporary file if you need it.
replies(1): >>42476749 #
9. santoshalper ◴[] No.42475919{4}[source]
Actually, parent is wrong. You're not supposed to do that shit on Windows either. That's what AppData is for. Writing configuration files and folders to "Documents" or the user's home folder is sloppy shit.
replies(1): >>42476264 #
10. ChocolateGod ◴[] No.42475939[source]
NixOS user here, where running precompiled binaries from your downloads folder won't work.

Could you look at supporting a Flatpak for Linux? If unsure, I'll happily throw a manifest together and post it on a MR.

replies(2): >>42476358 #>>42480645 #
11. znpy ◴[] No.42475958[source]
thank you for the great work!
12. bisby ◴[] No.42476022[source]
Sorry, to be clear, I dont wan't Grayjay data in my user directory AT ALL. Portable is basically what I want, I'm just very untactfully dropping feedback about where the data is placed.

Even with the "Portable" file, it creates a directory `/home/bisby/Grayjay`. I don't want that. No app should ever put a file or directory directly in `/home/bisby` without me asking it to. The Linux standard for "where should an app put it's files" is defined the XDG spec that I had previously linked (https://specifications.freedesktop.org/basedir-spec/latest/).

The summary is that user specific data should live in $XDG_DATA_HOME and config should live in $XDG_CONFIG_HOME (and various other things like $XDG_CACHE_HOME). If these values are unset, there are predefined places to put the files (eg, data in $HOME/.local/share or config in $HOME/.config, cache in $HOME/.cache).

This puts all the Grayjay data in places like /home/bisby/.config/Grayjay (instead of /home/bisby/Grayjay) which is nested away inside a hidden directory and structured in a consistent way.

This would be the equivalent of putting data in %AppData% in windows instead of cluttering someone's "My Documents" (or whatever the modern equivalent of that is).

Some of the Linux decisions feel a bit like linux is a complete afterthought, but included because Linux users tend to agree with the FUTO philosophies. That is a reasonable thing given the Linux market share, and for "Build Version: 2" that I'm seeing the app info, I'm grateful that linux is included this early. This looks like it can probably replace freetube for me. However, it would go a long way if things are done to make sure they are done the "right way" on Linux (ie, on packaging and on directory specs).

Thanks for the work you've done on freeing up the web.

replies(3): >>42476055 #>>42477386 #>>42478673 #
13. ◴[] No.42476055{3}[source]
14. SpaghettiCthulu ◴[] No.42476133{4}[source]
Ah, right. Good point!
15. sunshowers ◴[] No.42476264{5}[source]
I agree that this should be in the XDG directory or AppData, but be kind, y'all -- this is open source, it is a gift someone has labored over and given you. There are much nicer ways to suggest improvements than calling it "sloppy shit".

edit: it's not actually open source by the OSI definition it seems [1], but it is reasonably close.

[1] https://futo.org/about/futo-statement-on-opensource/

replies(1): >>42476385 #
16. atoav ◴[] No.42476313[source]
Please just adhere to the XDG-standards. Although my co-poster here didn't use the most diplomatic way of phrasing their grievance Grayjay is better off if it sticks to well established standards.

You would probably look weird at an software that installs itself in C:\MYAWESOMEAPPLICATION instead of using the Windows program folder like literally every other piece of software (except for legacy stuff like LTSpice). Creating visible directories in the home folder without asking is the Linux equivalent of doing just that.

Check if the XDG environment variables are set and store your stuff in these places — as it is now can be used as a last resort fallback. For reading config/data you do the same.

replies(1): >>42477795 #
17. Zefiroj ◴[] No.42476358{3}[source]
nix-ld[1] and envfs[2] provide a decent workaround for unpatched binaries, in case you haven't heard of these tools yet.

[1] https://github.com/nix-community/nix-ld [2] https://github.com/Mic92/envfs

The blog post linked by [1] is quite good.

replies(1): >>42476538 #
18. StrangeDoctor ◴[] No.42476385{6}[source]
Sure, things can always have gone better, but this is data loss/corruption territory. It's asking for trouble and hurt feelings. I think a strong response is ok.
19. Teever ◴[] No.42476531{4}[source]
What exactly is wrong with how they expressed themselves?

Is the word "hate" really so odious?

replies(1): >>42476990 #
20. ChocolateGod ◴[] No.42476538{4}[source]
I use NixOS for the base system and Flatpak+Containers for everything else. I would rather keep it this way as it keeps everything nice and separated, and less chance of things breaking from Nix being rolling.
21. LeonB ◴[] No.42476749{4}[source]
And if you’re feeling particularly Sadomasochistic there’s always the Windows Registry.
replies(1): >>42477874 #
22. bisby ◴[] No.42476990{5}[source]
I was very blunt and impersonal. People worked hard on a thing and my first reaction was criticism, without even the added overall view of "I love this thing, but here is a small thing that bothers me." I could have been more courteous and human about things.

I stand by the points I made, but I could have been friendlier. I normally make an effort to be friendly as I can about things, but I absolutely did not here. I hope that nothing I said came across as vitriol, but rather, valid criticism. I'm a strong believer in criticizing the things you love, but I need to remember that random comments on HN aren't the place where people know I love the thing, and my criticism needs context.

So no, it wasn't really that odious, but it was other things. Do I feel stricken with guilt or remorse about what I said? No. Could I have been friendlier? yes. Should I have been friendlier? Probably.

replies(1): >>42477744 #
23. karlgkk ◴[] No.42477386{3}[source]
If you're launching it as "Portable", and you're launching it from your home directory, it's going to place the mutable data in the current directory. This is very standard for portable apps.

So no, "portable" is not what you want. If you launch it as non-portable and it drops a folder in ~, then that is a problem.

replies(2): >>42477479 #>>42477669 #
24. bisby ◴[] No.42477479{4}[source]
In both modes it creates a ~/Grayjay directory, even when launching from ~/tmp/grayjay/Grayjay.Desktop-linux-x64-v2/ so ~/Grayjay was inevitable. In portable mode it makes the directory and does nothing with it. In non-portable mode it dumps a ton of data into the directory. I didn't pay attention to what the data actually was. So yes you're probably right.

But either way, Portable mode isn't behaving portably because it's touching directories outside of the current directory, and non-portable mode is putting data in ~/Grayjay instead of ~/.config/Grayjay so it doesn't do what I want it to do in any mode.

I'm quite happy actually that while this is a HUGE annoyance... It's also only an annoyance, and VERY simple to fix (as long as they do). Which means that this app is likely going to wind up as a daily driver for me once a few things get ironed out. I see the concept and structure of the app, and I like it.

replies(2): >>42478071 #>>42480597 #
25. Suppafly ◴[] No.42477625{4}[source]
>Parent is not wrong, but definitely could have some improved manners and tact.

I don't understand the weird tone policing that people are trying to do, there is literally nothing wrong with the parent's comment and pretending otherwise is weird.

replies(1): >>42478160 #
26. edflsafoiewq ◴[] No.42477669{4}[source]
Typically portable apps place their data in the folder where the executable file is located, not the current dir.
27. acjohnson55 ◴[] No.42477744{6}[source]
I appreciate the reflection here.
28. nullpoint420 ◴[] No.42477795{3}[source]
This. Hopefully the other post won't discourage them!
29. chupasaurus ◴[] No.42477874{5}[source]
Hey, that's NSFW content on HN!

Also I still find it funny that OpenSSH client shipped via feature uses %HOMEDIR%\.ssh

30. ◴[] No.42478071{5}[source]
31. gtsop ◴[] No.42478160{5}[source]
I didn't see it as tone policing. From my point of view, I saw a very interesting application being shared and I hoped it would be good and prosperous so i can use it. When the first comment says "i hate that you do X" it is a bit discouraging towards a team of developers who have probably poured tons of free hours into making this. Words play with psychology, and it is my personal interest that these devs have good morale to make this app great, and that meand giving them feedback about obvious mistakes in a tone that does not hurt this morale. I hope that make sense
replies(3): >>42478609 #>>42478968 #>>42480795 #
32. Suppafly ◴[] No.42478609{6}[source]
"i hate that you do x" is perfectly normal, you're being weird.
replies(2): >>42479591 #>>42480935 #
33. gf000 ◴[] No.42478673{3}[source]
Well, ideally I would like the OS solving this problem by simply chrooting/sandboxing apps to their own little worlds, with a proper API giving them optionally a way to the user's file system, similarly to android and iOS.
replies(2): >>42479201 #>>42479359 #
34. wkat4242 ◴[] No.42478968{6}[source]
I don't think it's badly worded either.

And FUTO is a commercial for-profit operation, not voluntary driven. Their devs are paid.

35. ThatMedicIsASpy ◴[] No.42479118[source]
I gave too many shits about my home dir once too..

My only correct way today is create your own home dir inside your home dir to combat this hell hole of never ending config junk in your home dir

replies(1): >>42480341 #
36. doodlesdev ◴[] No.42479201{4}[source]
That is possible on Linux [0], but this kind of separation comes with its own can of worms. However, if your only worry is access to folders, Flatpak applications keep all of their data in a folder away from your home directory and use "portals" to access your system [1]. The security of the sandbox is debatable [2], but I would say if your biggest goal is containing non-malicious but badly behaving applications from messing with your system, then it's a very good solution, given you are comfortable with using Flathub (as most distributions won't build Flatpaks) and with the performance/integration impact this distribution method has.

[0]: https://docs.flatpak.org/en/latest/basic-concepts.html

[1]: https://docs.flatpak.org/en/latest/sandbox-permissions.html

[2]: https://flatkill.org/2020/

37. isametry ◴[] No.42479359{4}[source]
…and macOS. Sandboxed Mac apps get their own little home directory in `~/Library/Containers/`. To access anything else, they need to ask through system APIs.
38. braiamp ◴[] No.42479591{7}[source]
And that's not even the words used, they said:

> I absolutely hate <stuff that does X> like this

replies(1): >>42481710 #
39. quotemstr ◴[] No.42480341[source]
It's a "green m&ms" thing. If the developers can't be bothered to adhere to something as basic as XDG, they're getting a ton of other things wrong, and my life is too short to spend on buggy slop.
replies(1): >>42481606 #
40. koen31 ◴[] No.42480597{5}[source]
Grayjay dev here, empty dir is definitely not intended and has been written down on the issue list.
replies(1): >>42481151 #
41. koen31 ◴[] No.42480645{3}[source]
Grayjay dev here, we want to provide the app however people want to consume it (binaries, flatpak, appimage, ...) but it will take us some time to get everything as it should be.
42. virtualritz ◴[] No.42480795{6}[source]
This is a cultural problem.

What is considered impolite in the US or the UK is considered just being straightforward in e.g. Scandinavia.

I am German, we're kind of in the middle between someone from e.g. Finland and someone from e.g. or the UK or US with what we consider "ok" or rather crossing into rude territory.

A common exchange I witnessed in a meeting at work (Nokia):

Finnish developer: And if we follow this suggestion we will all look like idiots.

UK developer: I hear you.

Deciding which one is more impolite or impolite at all is left as an exercise to the reader. ;)

You get my point.

replies(1): >>42484863 #
43. nozzlegear ◴[] No.42480935{7}[source]
Taking "I hate that you do x" as a combative or rude dismissal is perfectly normal too.
replies(1): >>42484857 #
44. ◴[] No.42481151{6}[source]
45. ThatMedicIsASpy ◴[] No.42481606{3}[source]
It is not really. If you show hidden files there is a ton of junk folders above your non hidden folders. along with more junk like folders generated by the system. I can't be arsed to go look up ways to keep them from returning or manage when I can just have my stuff reside in my own organization. Windows user folder isn't better and Microsoft also adds tons of junk folders (3D Objects, Contacts, Links, Favorites, Searches, Saved Games)
replies(1): >>42481658 #
46. quotemstr ◴[] No.42481658{4}[source]
> It is not really.

Yes, it is. It takes only a few minutes to comply with the XDG spec. If an author can't be bothered to do that, he probably hasn't bothered to make his program secure, stable, or extensible either. XDG non-adherence is a strong negative quality signal.

47. bisby ◴[] No.42481710{8}[source]
That's not even the words I used either.

> I absolutely hate having stuff automatically create anything in my home directory like this.

Which is

> I absolutely hate <action> like this

Which is not

> I absolutely hate <thing that does action> like this

I quite like grayjay. I just dislike this one thing it does.

48. retrochameleon ◴[] No.42482018[source]
You'd be interested in xdg-ninja: https://github.com/b3nj5m1n/xdg-ninja

Like others said, fighting the clean HOME fight is just draining and futile in the end. This script helps you identify low hanging fruit, though, where you can change their storage location with a simple envvar.

replies(1): >>42482696 #
49. bisby ◴[] No.42482696[source]
I've used xdg-ninja. And it does feel futile. Which is why my original comment comes across a bit more as frustrated/exasperated bug report than an HN comment.

Right now everything that xdg-ninja finds are all things with a .prefix and hidden. which is whatever. if this was ~/.grayjay, I probably would have rolled my eyes but not even bothered to comment. I'm not a stickler about XDG, but I am a bit of a stickler about not cluttering my home directory.

50. jffasdfwau ◴[] No.42483636[source]
Thank you. I thought I was alone in caring about XDG specification.
51. Suppafly ◴[] No.42484857{8}[source]
nah, you're weird.
replies(1): >>42484929 #
52. Suppafly ◴[] No.42484863{7}[source]
It's not even impolite in the US, the people tone policing are being very weird. It's perfectly normal to say "I hate x behavior".
replies(1): >>42484941 #
53. ◴[] No.42484929{9}[source]
54. nozzlegear ◴[] No.42484941{8}[source]
It's not normal to see someone doing x behavior, initiate a conversation with them and say "I hate x behavior." They're not tone policing you when they tell you that you come off like an asshole when you do that.
replies(1): >>42485023 #
55. Suppafly ◴[] No.42485023{9}[source]
That's not at all what's happening here so it's irrelevant.