Treats nonexistent files like read-only

Bug #1038291 reported by Sergey "Shnatsel" Davidoff
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Scratch
Fix Released
High
Darcy Luís Neves Brás da Silva

Bug Description

If Scratch is passed a file name on the command line for a file which does not exist, it treats it as read-only file, which is obviously wrong.

The Right Thing To Do is not obvious, though. Gedit creates the given files in such cases. For Scratch, which does everything to always show the current state of the file, I'd go with "No file = empty file". This means no infobars and creating the file on first edit. The use case for this would be continuously monitoring a file which is yet to be created (e.g. log file).

Disclaimer: this is the weirdest thing I did to Scratch so far.

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: scratch-text-editor 1.1.1+r862-0+pkg29~precise1 [origin: LP-PPA-elementary-os-daily]
ProcVersionSignature: Ubuntu 3.2.0-27.43-generic 3.2.21
Uname: Linux 3.2.0-27-generic x86_64
ApportVersion: 2.0.1-0ubuntu11
Architecture: amd64
CrashDB: scratch_text_editor
Date: Sat Aug 18 02:08:50 2012
ExecutablePath: /usr/bin/scratch-text-editor
InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Alpha amd64 (20120303)
ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 LANG=ru_RU.UTF-8
 SHELL=/usr/bin/fish
SourcePackage: scratch-text-editor
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Sergey "Shnatsel" Davidoff (shnatsel) wrote :
description: updated
description: updated
Changed in scratch:
status: New → Confirmed
importance: Undecided → High
milestone: none → 1.2
Changed in scratch:
assignee: nobody → Darcy Luís Neves Brás da Silva (darcy-develin)
Changed in scratch:
status: Confirmed → In Progress
Changed in scratch:
status: In Progress → Fix Committed
Changed in scratch:
status: Fix Committed → Fix Released
Changed in scratch:
status: Fix Released → Fix Committed
Cody Garver (codygarver)
Changed in scratch:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.