Skip to content
Snippets Groups Projects
Commit e343a860 authored by Karl Fogel's avatar Karl Fogel
Browse files

Remove version control handling of the config area.

Thus also get rid of the ~/.onetime/config file entirely, as the only
thing in it was the 'use-vc' parameter.  If we ever want to have a
config file for some other reason, look in this commit first.

There are several good reasons not to do VC on ~/.onetime/ anymore.
Most users don't expect it, so it violates the Principle of Least
Astonishment.  Even having it default to off, with permanent and
run-time options to turn it on, doesn't entirely solve this: a typical
user probably uses OneTime only rarely, and is likely to forget that
VC is on even if they turned it on themselves.  Then when a command
takes a long time, or fails to complete because a network connection
is down, they'll wonder what's going on.  Furthermore, automated VC
runs the risk of signalling a network observer that OneTime is being
invoked -- that's downright risky, and it's unreasonable to depend on
the user to remember this possibility before they run the program.
Furthermore, the code needed to add Git and possibly Mercurial
support, in addition to the Subversion and CVS support already
present, would have been complicated because of Git's more complicated
conception of upstream repositories, and the chances of something
going wrong on a VC operation would have increased.  In short, VC was
about to get more complicated, more error-prone, and less predictable,
on top of all the problems it already had.  I strongly suspect I was
the only person using it anyway, and I'm happy to do without it.

* onetime: Don't import ConfigParser.
  (Configuration.ConfigurationVCError): Remove.
  (Configuration.__init__): Don't take use_vc parameter.
    Don't set up nor parse a config file.
  (Configuration._directory_vc): Remove.
  (Configuration._maybe_do_vc_operation): Remove.
  (Configuration._maybe_update_pad_records): Remove.
  (Configuration._maybe_commit_pad_records): Remove.
  (Configuration.save): Adjust for above.
  (usage): Don't mention --use-vc and --no-vc options.
  (main): Don't handle --use-vc and --no-vc options.

* index.html-top: Adjust for above.
parent 3143ab39
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment