After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 699642 - Change Autosave Location
Change Autosave Location
Status: RESOLVED WONTFIX
Product: gnome-settings-daemon
Classification: Core
Component: media-keys
3.8.x
Other Linux
: Normal enhancement
: ---
Assigned To: gnome-settings-daemon-maint
gnome-settings-daemon-maint
: 699276 729610 747335 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2013-05-03 22:36 UTC by Sudhir Khanger
Modified: 2021-02-21 23:53 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Sudhir Khanger 2013-05-03 22:36:29 UTC
I used to be able to save screenshots in a user specified location which no longer works in Gnome 3.8. All screenshots taken are saved in Pictures folder which really clutters it. Ability to define a specific folder to autosave screenshots is a must.

Old method which no longer works is through dconf-editor>org>gnome>gnome-screenshots>auto-save-directory.

Thanks.
Comment 1 cowboycamilo 2013-05-03 22:55:19 UTC
I can Confirm bug.
I can define the folder, but the screenshot is still saved in Pictures folder.
there are so many files in that folder (5 or 6 years of family pics) that it's not usable for day to day work.
Comment 2 Matthias Clasen 2013-05-04 03:13:25 UTC
Works just fine here. What are you setting the key to ?
Comment 3 cowboycamilo 2013-05-04 03:26:04 UTC
I'm setting it up to my desktop,  [/home/user/Desktop]
Comment 4 Sudhir Khanger 2013-05-04 23:51:51 UTC
I am using file:///home/donnie/Downloads/Screenshots

http://imgur.com/ETH1fsE
Comment 5 Matthias Clasen 2013-05-05 16:12:23 UTC
(In reply to comment #3)
> I'm setting it up to my desktop,  [/home/user/Desktop]

try file:///home/user/Desktop
Comment 6 Matthias Clasen 2013-05-05 16:12:43 UTC
(In reply to comment #4)
> I am using file:///home/donnie/Downloads/Screenshots
> 

Does the directory exist ?
Comment 7 Sudhir Khanger 2013-05-05 20:36:10 UTC
Yes, of course. http://imgur.com/jjYyreh

Does gnome-screenshot keep log files somewhere that can be more helpful to locate the problem.
Comment 8 Matthias Clasen 2013-05-05 21:42:14 UTC
Oh, indeed, I see the problem now. gnome-settings-daemon just passes a filename, to gnome-shell, not a complete path. And gnome-shell always saves in ~/Pictures.

Moving this bug to gnome-shell
Comment 9 Matthias Clasen 2013-05-05 21:42:49 UTC
The relevant function is get_stream_for_filename in src/shell-screenshot.c
Comment 10 Florian Müllner 2013-05-05 21:45:59 UTC
(In reply to comment #9)
> The relevant function is get_stream_for_filename in src/shell-screenshot.c

It's called from prepare_write_stream(), and only for relative filenames. If gnome-screenshot passed an absolute path, it should work just fine ...
Comment 11 Florian Müllner 2013-05-05 21:49:54 UTC
(In reply to comment #10)
> it should work just fine ...

... and it does in my testing:

$ gsettings set org.gnome.gnome-screenshot auto-save-directory '/home/florian/tmp'
$ gnome-screenshot
$ ls ~/tmp/*.png
/home/florian/tmp/Screenshot from 2013-05-05 23:47:36.png
Comment 12 Florian Müllner 2013-05-05 21:55:46 UTC
(In reply to comment #8)
> Oh, indeed, I see the problem now. gnome-settings-daemon just passes a
> filename, to gnome-shell, not a complete path. And gnome-shell always saves in
> ~/Pictures.

Oh, you said gnome-settings-daemon. Can't g-s-d optionally pass an absolute path as gnome-screenshot does?
Comment 13 cowboycamilo 2013-05-06 22:44:25 UTC
I tried manually to set the path in dconf-editor with no luck, I tried [file:///home/cowboycamilo/desktop] ando also tried [~/Desktop] none work..
I did a screencast for you all here: http://www.youtube.com/watch?v=seAeelxLmxc&feature=youtu.be
Comment 14 Matthias Clasen 2013-05-06 22:51:59 UTC
(In reply to comment #12)
> (In reply to comment #8)
> > Oh, indeed, I see the problem now. gnome-settings-daemon just passes a
> > filename, to gnome-shell, not a complete path. And gnome-shell always saves in
> > ~/Pictures.
> 
> Oh, you said gnome-settings-daemon. Can't g-s-d optionally pass an absolute
> path as gnome-screenshot does?

Sure, it could. Lets move this to gsd then
Comment 15 Bastien Nocera 2013-05-07 05:30:59 UTC
Sorry, I'm not interested in providing more moving parts in this section of the code.

You can call the gnome-screenshot binary custom shortcuts and it will respect its own configuration options and save the files in the directory you want.
Comment 16 Sudhir Khanger 2013-05-24 15:10:46 UTC
Is this the end of this and I should move on other other screenshot utility as clearly Gnome/Gnome-screenshot is too primitive or are we working out some other route to resolve this?
Comment 17 Bastien Nocera 2013-05-24 15:16:40 UTC
(In reply to comment #16)
> Is this the end of this and I should move on other other screenshot utility as
> clearly Gnome/Gnome-screenshot is too primitive or are we working out some
> other route to resolve this?

You can use gnome-screenshot to save wherever you want, just create a custom keyboard shortcut for it in the keyboard settings panel.
There won't be a configuration option to do this in gnome-settings-daemon, as it's already trivially possible to work-around this lack of configuration.
Comment 18 Sudhir Khanger 2013-05-24 15:30:47 UTC
hmm How do I define the location. I checked the man pages of gnome-screenshot and I couldn't find information about defining location. Could you please provide a sample command?

Using -f option would let me define custom path of a file but not a default folder.

gnome-screenshot -w -f ~/Downloads/Screenshots/

** (gnome-screenshot:10189): CRITICAL **: Unable to save the screenshot: Error opening file '/home/donnie/Downloads/Screenshots': Is a directory

[donnie@donnie-laptop ~]$ gnome-screenshot -w -f ~/Downloads/Screenshots/screen1.png

If I define path and filename it works but when I just define folder it won't work.

Thanks.
Comment 19 Florian Müllner 2013-05-24 15:46:02 UTC
gnome-screenshot still uses the auto-save-directory setting. Set the key to '/home/donnie/Downloads/Screenshots' or whatever you want, then define a custom shortcut using 'gnome-screenshot' as command.
Comment 20 Sudhir Khanger 2013-05-25 14:15:08 UTC
Thanks Florian that did the trick.
Comment 21 Bastien Nocera 2014-05-06 14:59:13 UTC
*** Bug 729610 has been marked as a duplicate of this bug. ***
Comment 22 Marius Andreiana 2014-05-26 14:28:14 UTC
@Bastien if you're not interested, would you please leave the bug open for somebody else to take this?

As you can see from this and the other dupe bug report, there's definitely interest from users in this. See also https://marteydodoo.com/writing/2013/12/15/saving-screenshots-different-directory-gnome-3/

Thanks
Comment 23 Bastien Nocera 2014-05-26 14:58:42 UTC
(In reply to comment #22)
> @Bastien if you're not interested, would you please leave the bug open for
> somebody else to take this?

No, because the code for it won't go in gnome-settings-daemon. Keeping this bug opened wouldn't make any sense.
Comment 24 Marius Andreiana 2014-05-26 15:14:41 UTC
Where would it go? So I can file a bug for that component.

I assume not 'gnome-screenshot', as handling that as a separate app was discussed above.
Comment 25 Vinothan Shankar 2015-06-25 22:55:12 UTC
(In reply to Bastien Nocera from comment #17)
> There won't be a configuration option to do this in gnome-settings-daemon,
> as it's already trivially possible to work-around this lack of configuration.

When your application saves to a hardcoded path, that's a bug - especially since as a number of bug reports note, the behaviour when the directory in question doesn't exist is ill-defined.  It is, quite simply, *not your job* to tell the user how they should organise their files.

When the application's predecessor, with which it shares a chunk of code, supported arbitrary paths to deal with this exact problem, that's a *regression*.

And when your entire response to these being raised as issues boils down to "but I don't *wanna* fix it", and you're suggesting that it's better for any user who wants their screenshot tool to respect their filesystem layout to perform a configuration tweak that involves changing *thirteen times* as many options as were necessary to make the previous tool behave sanely, that's plain childish.
Comment 26 Christian Stadelmann 2015-11-18 21:17:33 UTC
Please reopen this issue, it is still present on 3.18.x and annoys some users. I for example don't want any software to mess up my ~/Pictures folder.
Comment 27 Paul Wise 2016-09-08 07:27:28 UTC
This bug is quite annoying. For anyone wondering how to workaround this bug, check out this recent blog post from Planet Fedora:

http://cialu.net/blog/gnome-screenshot-folder.html
Comment 28 Gwendal 2016-09-14 07:58:31 UTC
I would also be interested in a fix here.
Comment 29 Daniel Boles 2017-09-01 14:00:31 UTC
*** Bug 699276 has been marked as a duplicate of this bug. ***
Comment 30 Daniel Boles 2017-09-01 14:00:41 UTC
*** Bug 747335 has been marked as a duplicate of this bug. ***
Comment 31 Célestin Taramarcaz 2017-10-27 09:50:05 UTC
Same problem here with GNOME Shell 3.26.1 (Ubuntu 17.10). Even when auto-save folder is specified using 'gsettings set org.gnome.gnome-screenshot auto-save-directory' screenshots are still saved to /home.
Comment 32 Florian Müllner 2017-10-27 11:19:00 UTC
As explained about a thousand times:
When using the PrintScrn shortcuts, gnome-screenshot is *not* involved at all, so its preferences don't apply. You can make an argument that gnome-settings-daemon should have a similar setting (although that request has been rejected in the past), but complaining that the existing setting is "ignored" is like complaining that Chromium "ignores" your Firefox settings ...
Comment 33 Joe Mooring 2017-10-29 13:47:31 UTC
Can we please re-open this enhancement request?

1. Add a dconf/gsettings key:
org.gnome.settings-daemon.plugins.media-keys screenshot-save-directory

2. The format of this key should be 'file:///foo'

3. The default value of this key should be 'file:///$HOME/Pictures'

4. gnome-settings-daemon should use this setting

Justification:

1. Many users have asked for this. See issues closed as a duplicate of this one, stackexchange, askubuntu, etc.

2. This issue will become more prevalent as more users upgrade from Ubuntu 17.04/Unity to Ubuntu 17.10/GNOME.

3. The suggested work-around requires six custom keyboard shortcuts to override current keyboard shortcuts (PrtSc, Alt+PrtScr, Shift+PrtScr, Ctrl+PrtScr, Ctrl+Alt+PrtScr, Ctrl+Shift+PrtScr).

4. "I'm not interested in providing more moving parts in this section of the code" is an unacceptable reason to reject this enhancement request.
Comment 34 Vinothan Shankar 2017-10-30 11:44:26 UTC
(In reply to Florian Müllner from comment #32)
> As explained about a thousand times:
> When using the PrintScrn shortcuts, gnome-screenshot is *not* involved at
> all, so its preferences don't apply. You can make an argument that
> gnome-settings-daemon should have a similar setting (although that request
> has been rejected in the past), but complaining that the existing setting is
> "ignored" is like complaining that Chromium "ignores" your Firefox settings
> ...

It's more like complaining that (to take a real-world example) Firefox 44 removed the option to prompt for acceptance or rejection of every cookie, and now ignores the setting and just accepts them - or rather, it would be like that if they'd also removed the option to /blanket/-ignore cookies, and hardcoded the accept behaviour.  Plenty of other settings had equivalents from GNOME2 to GNOME3 which were automatically migrated.  This one was simply removed, and not only that but no notification of the regression was given at the time.

That's a pretty valid complaint.

(in reply to Bastien Nocera from comment #17)
> There won't be a configuration option to do this in gnome-settings-daemon, as it's already trivially possible to work-around this lack of configuration.
(...and comment #23)
> > can we leave the bug open for someone else to fix?
> No, because the code for it won't go in gnome-settings-daemon.

I understand you're not interested in providing this fix - and it /is/ a fix; it's a regression that is actively making life difficult for people who want a sane folder-organisation structure - but am I to understand that you'll also be rejecting a patch written by anyone /else/ to solve it?
Comment 35 mehaase 2018-01-19 15:17:43 UTC
+1 to what Joe and Vinothan said above. Whether this is a bug or a feature request, and whether it exists in gnome-screenshot or gnome-settings daemon, the arguments against this ticket are very nitpicky and completely miss the point: this is a real usability problem!
Comment 36 mehaase 2018-01-19 15:38:29 UTC
I should also add that with Ubuntu 17.10 now shipping Gnome desktop by default, you suddenly have a huge influx of new users who used to be able to configure the screenshot directory and have now lost that feature. That's not Gnome's fault, of course, but it does suggest that demand for this feature just spiked recently.
Comment 37 Colan Schwartz 2018-07-26 13:41:27 UTC
https://extensions.gnome.org/extension/1179/screenshot-locations/ appears to be a workaround for this, but I'm not sure how effective it is yet.
Comment 38 mehaase 2018-07-26 14:39:37 UTC
Colan: I just installed that extension and it solves the issue perfectly. Thank you for posting the link.
Comment 39 L. López 2018-09-27 16:03:11 UTC
(In reply to Colan Schwartz from comment #37)
> https://extensions.gnome.org/extension/1179/screenshot-locations/ appears to
> be a workaround for this, but I'm not sure how effective it is yet.

Another 'thank you', it's a shame that this bug is closed with WONTFIX.

I decided to break with the 90's schema of Images/Videos/Documents (seriously, who organizes its files in folder by media type nowadays?)

I lost nearly an hour until I fix my environment.

With those decisions it's how Gnome loses users.
Comment 40 Armin Beširović 2018-11-20 12:44:27 UTC
The workaround to this is to disable the shortcuts in the Keyboard Shortcuts (click on it then Backspace) and add new custom ones which use gnome-screenshot. I use Shift + Print Screen for an area screenshot which just runs "gnome-screenshot -a"
Comment 41 fcole90 2019-03-02 17:17:04 UTC
This bug was reported the first time 5 years ago. Is it possible to reconsider the decision, given how many users are affected and willing to see this solved?

How much complexity would this add to g-s-d? How much does it break users' daily usability of the system?

Indeed it's possible to workaround this, with the easiest method being the aforementioned extension (https://extensions.gnome.org/extension/1179/screenshot-locations/). The other mentioned workarounds are only partial and require disabling the default shortcuts in order to create custom ones, which makes the process quite cumbersome.
Comment 42 Benjamin Berg 2019-03-02 22:43:32 UTC
I am not convinced that adding a new option to g-s-d is a great plan and we don't want to end up with multiple options. So, we would either need to run gnome-screenshot (which seems like overkill) or have a common location configuration for both gnome-screenshot and g-s-d.
Comment 43 fcole90 2019-03-03 11:54:49 UTC
I'm thinking to something simple, like a gsettings key:value that a user can edit like the following:

```
gsettings set org.gnome.settings-daemon.screenshot folder '/home/user/Pictures/Screenshots'
```

It could have the default value set to 'XDG_PICTURES_DIR', so to keep the default behaviour as it is at the moment. In this way g-s-d could read the value from gsettings, but the users would be able to set a different value from that.

Do you think something like that could be a good trade-off to keep the code modification minimal but still allowing users to have it editable?
Comment 44 Benjamin Berg 2019-03-03 21:31:51 UTC
As I said, I don't think that having two options for the same thing (one for g-s-d one for gnome-screenshot) is a decent solution.
Comment 45 Marcin Zajaczkowski 2019-09-12 20:15:58 UTC
Distressed by the Pictures directory cluttered with the screenshot files I wanted to ask about that and I have found that issue.

It still would be good to have any solution without a need to leverage a 3rd-party extension (or creating custom shortcuts) to change a directory for screenshots implemented in the way that satisfies the developers of related components.
Comment 46 oDarek 2021-02-21 21:23:22 UTC
Hi,

This didn't work for many years :(
is anybody working on this?

Best regards,
oDarek
Comment 47 Paul Wise 2021-02-21 23:53:52 UTC
This bug is officially closed and also this Bugzilla site is no longer used by the GNOME project.

There are two workarounds for this issue documented above:

There is a GNOME shell extension, which works on some versions but not others:

https://extensions.gnome.org/extension/1179/screenshot-locations/
https://codeberg.org/kiyui/gnome-shell-screenshotlocations-extension/issues/7

You can customise each of the PrtSc, Alt+PrtScr, Shift+PrtScr, Ctrl+PrtScr, Ctrl+Alt+PrtScr, Ctrl+Shift+PrtScr commands to run gnome-screenshot instead.

If anyone wants to write a patch for this it will need to be submitted to gnome-shell's new GitLab project:

https://gitlab.gnome.org/GNOME/gnome-shell/