9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] Acme Configuration
@ 2009-08-07  8:37 Aaron W. Hsu
  2009-08-07  9:20 ` Daniel Lyons
  2009-08-07 20:07 ` Uriel
  0 siblings, 2 replies; 18+ messages in thread
From: Aaron W. Hsu @ 2009-08-07  8:37 UTC (permalink / raw)
  To: 9fans

Other than a script to start acme with the -a option, is there some way to
configure the start up option on Acme? I am thinking of the equivalent of
a .exrc file or the like?

	Aaron W. Hsu

--
Of all tyrannies, a tyranny sincerely exercised for the good of its
victims may be the most oppressive. -- C. S. Lewis



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07  8:37 [9fans] Acme Configuration Aaron W. Hsu
@ 2009-08-07  9:20 ` Daniel Lyons
  2009-08-07  9:39   ` erik quanstrom
  2009-08-07 13:34   ` Jason Catena
  2009-08-07 20:07 ` Uriel
  1 sibling, 2 replies; 18+ messages in thread
From: Daniel Lyons @ 2009-08-07  9:20 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs


On Aug 7, 2009, at 2:37 AM, Aaron W. Hsu wrote:

> Other than a script to start acme with the -a option, is there some  
> way to configure the start up option on Acme? I am thinking of the  
> equivalent of a .exrc file or the like?


Generally you set it up the way you like, then run Dump. This creates  
a file acme.dump in your home directory. Then you can run acme -l  
acme.dump and it will restore itself to those settings, which are  
basically the frames, what files are open and what fonts you're using.  
You can also edit that file and dink around with it.

By default I think rio runs acme with -l lib/acme.dump, but you can  
certainly have as many of these around as you'd like.

—
Daniel Lyons




^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07  9:20 ` Daniel Lyons
@ 2009-08-07  9:39   ` erik quanstrom
  2009-08-07 13:34   ` Jason Catena
  1 sibling, 0 replies; 18+ messages in thread
From: erik quanstrom @ 2009-08-07  9:39 UTC (permalink / raw)
  To: 9fans

> By default I think rio runs acme with -l lib/acme.dump, but you can
> certainly have as many of these around as you'd like.

this is controlled by lib/profile, rather than rio.

- erik



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07  9:20 ` Daniel Lyons
  2009-08-07  9:39   ` erik quanstrom
@ 2009-08-07 13:34   ` Jason Catena
  2009-08-07 13:50     ` Noah Evans
  1 sibling, 1 reply; 18+ messages in thread
From: Jason Catena @ 2009-08-07 13:34 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

I keep many dump files around with different names, to easily suspend,
switch, and resume acme configurations depending on what I need to
work on.  This significantly reduces my context switch time, over and
above the advantage I get from guide files keeping me from
(mis)retyping commands.

in acme: highlight and execute "Dump /home/me/dump/whatever"
in shell: rum "acme -l /home/me/dump/whatever"

Jason Catena



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 13:34   ` Jason Catena
@ 2009-08-07 13:50     ` Noah Evans
  2009-08-07 14:02       ` roger peppe
  0 siblings, 1 reply; 18+ messages in thread
From: Noah Evans @ 2009-08-07 13:50 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Aaron's problem is not dumping per se, it's saving his indentation and
other command line state between sessions. Unless there's something I
missed, you can only enable functions like auto-indent via the command
line(-a) or via "Indent on" in acme. The dump doesn't preserve indent
state so yes, Aaron needs a script.

Noah

On Fri, Aug 7, 2009 at 3:34 PM, Jason Catena<jason.catena@gmail.com> wrote:
> I keep many dump files around with different names, to easily suspend,
> switch, and resume acme configurations depending on what I need to
> work on.  This significantly reduces my context switch time, over and
> above the advantage I get from guide files keeping me from
> (mis)retyping commands.
>
> in acme: highlight and execute "Dump /home/me/dump/whatever"
> in shell: rum "acme -l /home/me/dump/whatever"
>
> Jason Catena
>
>



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 13:50     ` Noah Evans
@ 2009-08-07 14:02       ` roger peppe
  2009-08-07 14:28         ` Noah Evans
  0 siblings, 1 reply; 18+ messages in thread
From: roger peppe @ 2009-08-07 14:02 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

2009/8/7 Noah Evans <noah.evans@gmail.com>:
> The dump doesn't preserve indent state

personally, i think it should.

and some other stuff as well.



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 14:02       ` roger peppe
@ 2009-08-07 14:28         ` Noah Evans
  2009-08-07 15:42           ` roger peppe
  0 siblings, 1 reply; 18+ messages in thread
From: Noah Evans @ 2009-08-07 14:28 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

What other stuff are you thinking of?

On Fri, Aug 7, 2009 at 4:02 PM, roger peppe<rogpeppe@gmail.com> wrote:
> 2009/8/7 Noah Evans <noah.evans@gmail.com>:
>> The dump doesn't preserve indent state
>
> personally, i think it should.
>
> and some other stuff as well.
>
>



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 14:28         ` Noah Evans
@ 2009-08-07 15:42           ` roger peppe
  2009-08-07 15:48             ` erik quanstrom
                               ` (3 more replies)
  0 siblings, 4 replies; 18+ messages in thread
From: roger peppe @ 2009-08-07 15:42 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

the Include path.
contents of win buffers.
Undo/Redo history.

ok, the last might be pushing it a bit,
but ideally i'd like to be able to dump
an acme session and restore it without
any loss of continuity, and the Undo/Redo history
is a very useful part of my acme context.

while i'm about it, there are a few other dump
features i'd like to see:
- automatic dumping every 30s or so in case of a crash.
- Dump would dump to the restored-from file rather than
$home/acme.dump by default.
- atomic dump file creation - if, for some reason,
acme dies half-way through dumping, i don't
want the old dump file to be erased with a dud
new one.

most of this should be fairly straightforward,
i've just not made space in my life to do it yet.

and i doubt it would be accepted as a patch anyway.


2009/8/7 Noah Evans <noah.evans@gmail.com>:
> What other stuff are you thinking of?
>
> On Fri, Aug 7, 2009 at 4:02 PM, roger peppe<rogpeppe@gmail.com> wrote:
>> 2009/8/7 Noah Evans <noah.evans@gmail.com>:
>>> The dump doesn't preserve indent state
>>
>> personally, i think it should.
>>
>> and some other stuff as well.
>>
>>
>
>



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 15:42           ` roger peppe
@ 2009-08-07 15:48             ` erik quanstrom
  2009-08-07 16:05             ` ron minnich
                               ` (2 subsequent siblings)
  3 siblings, 0 replies; 18+ messages in thread
From: erik quanstrom @ 2009-08-07 15:48 UTC (permalink / raw)
  To: 9fans

> ok, the last might be pushing it a bit,
> but ideally i'd like to be able to dump
> an acme session and restore it without
> any loss of continuity, and the Undo/Redo history
> is a very useful part of my acme context.
>
> - Dump would dump to the restored-from file rather than
> $home/acme.dump by default.
> - atomic dump file creation - if, for some reason,
> acme dies half-way through dumping, i don't
> want the old dump file to be erased with a dud
> new one.
>
> most of this should be fairly straightforward,
> i've just not made space in my life to do it yet.
>
> and i doubt it would be accepted as a patch anyway.

it positively won't be accepted if it doesn't exist.

- erik



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 15:42           ` roger peppe
  2009-08-07 15:48             ` erik quanstrom
@ 2009-08-07 16:05             ` ron minnich
  2009-08-07 16:54             ` Noah Evans
  2009-08-07 17:23             ` yy
  3 siblings, 0 replies; 18+ messages in thread
From: ron minnich @ 2009-08-07 16:05 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Do you want to add all these features to acme, or is it possible to
have an external process which writes to acme ctl files and causes
these things to happen?

ron



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 15:42           ` roger peppe
  2009-08-07 15:48             ` erik quanstrom
  2009-08-07 16:05             ` ron minnich
@ 2009-08-07 16:54             ` Noah Evans
  2009-08-07 17:07               ` Iruata Souza
  2009-08-07 17:23             ` yy
  3 siblings, 1 reply; 18+ messages in thread
From: Noah Evans @ 2009-08-07 16:54 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

you mean outside of the dump when acme is dies for reasons other than
being killed/exited?

with win state, how are you going to handle the state of the shell? I
can see why they're dynamic, it could be potentially misleading to see
a changed namespace/rfork etc... and expect the shell to have the same
environment as the history.

I definitely like your restored from ideas.

I wouldn't worry about getting the patch accepted or not. Just go for it.




On Fri, Aug 7, 2009 at 5:42 PM, roger peppe<rogpeppe@gmail.com> wrote:
> the Include path.
> contents of win buffers.
> Undo/Redo history.
>
> ok, the last might be pushing it a bit,
> but ideally i'd like to be able to dump
> an acme session and restore it without
> any loss of continuity, and the Undo/Redo history
> is a very useful part of my acme context.
>
> while i'm about it, there are a few other dump
> features i'd like to see:
> - automatic dumping every 30s or so in case of a crash.
> - Dump would dump to the restored-from file rather than
> $home/acme.dump by default.
> - atomic dump file creation - if, for some reason,
> acme dies half-way through dumping, i don't
> want the old dump file to be erased with a dud
> new one.
>
> most of this should be fairly straightforward,
> i've just not made space in my life to do it yet.
>
> and i doubt it would be accepted as a patch anyway.
>
>
> 2009/8/7 Noah Evans <noah.evans@gmail.com>:
>> What other stuff are you thinking of?
>>
>> On Fri, Aug 7, 2009 at 4:02 PM, roger peppe<rogpeppe@gmail.com> wrote:
>>> 2009/8/7 Noah Evans <noah.evans@gmail.com>:
>>>> The dump doesn't preserve indent state
>>>
>>> personally, i think it should.
>>>
>>> and some other stuff as well.
>>>
>>>
>>
>>
>
>



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 16:54             ` Noah Evans
@ 2009-08-07 17:07               ` Iruata Souza
  2009-08-07 17:16                 ` erik quanstrom
  0 siblings, 1 reply; 18+ messages in thread
From: Iruata Souza @ 2009-08-07 17:07 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

On Fri, Aug 7, 2009 at 1:54 PM, Noah Evans<noah.evans@gmail.com> wrote:
> you mean outside of the dump when acme is dies for reasons other than
> being killed/exited?
>
> with win state, how are you going to handle the state of the shell? I
> can see why they're dynamic, it could be potentially misleading to see
> a changed namespace/rfork etc... and expect the shell to have the same
> environment as the history.
>

i've been thinking about that. maybe just dumping the win contents
(not the whole environment) would do the job.

iru



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 17:07               ` Iruata Souza
@ 2009-08-07 17:16                 ` erik quanstrom
  0 siblings, 0 replies; 18+ messages in thread
From: erik quanstrom @ 2009-08-07 17:16 UTC (permalink / raw)
  To: 9fans

>
> i've been thinking about that. maybe just dumping the win contents
> (not the whole environment) would do the job.
>

once upon a time, with a unix from long, long ago,
there was a local (?) derivative of csh that had "karma"
you could die and later reincarnate and get all
your old variables back.  great idea in theory.  until
you realize that all your old sins will be visited upon
you.

on the other hand, saving undo history would open
up new uses for acme.  i think that would be neat.

- erik



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 15:42           ` roger peppe
                               ` (2 preceding siblings ...)
  2009-08-07 16:54             ` Noah Evans
@ 2009-08-07 17:23             ` yy
  2009-08-07 18:50               ` Jason Catena
                                 ` (2 more replies)
  3 siblings, 3 replies; 18+ messages in thread
From: yy @ 2009-08-07 17:23 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

2009/8/7 roger peppe <rogpeppe@gmail.com>:
> the Include path.
> contents of win buffers.
> Undo/Redo history.

Contents of all the taglines

i have lost precious one-liners in column headers.

> while i'm about it, there are a few other dump
> features i'd like to see:
> - automatic dumping every 30s or so in case of a crash.

could this be done with a script?

> - Dump would dump to the restored-from file rather than
> $home/acme.dump by default.

i did this once. unfortunately, i cannot find that code.

> most of this should be fairly straightforward,
> i've just not made space in my life to do it yet.

i like to experiment with this kind of small changes in acme. i hope
to push my stuff to sources soon.

> and i doubt it would be accepted as a patch anyway.

very good judgement is needed to accept or reject acme patches.


--
- yiyus || JGL . 4l77.com



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 17:23             ` yy
@ 2009-08-07 18:50               ` Jason Catena
  2009-08-07 19:00               ` yy
  2009-08-08  4:16               ` 6o205zd02
  2 siblings, 0 replies; 18+ messages in thread
From: Jason Catena @ 2009-08-07 18:50 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

On Fri, Aug 7, 2009 at 12:23, yy<yiyu.jgl@gmail.com> wrote:
> 2009/8/7 roger peppe <rogpeppe@gmail.com>:
> Contents of all the taglines
>
> i have lost precious one-liners in column headers.

Didn't copy them into guide files in the current directory?  Seems to
work just as well for file commands, if not edit commands (which just
need copied back).

>> - Dump would dump to the restored-from file rather than
>> $home/acme.dump by default.

I put "Dump /where/ever/dumps/go" in the top tagline and highlight it,
works well enough for me.

> very good judgement is needed to accept or reject acme patches.

I can definitely attest to this principle in my own work.  In terms of
apprentice/journeyman/master for a particular program: the apprentices
write a lot of code, most of which is thrown away to get to a few good
ideas; the journeymen refine ideas into something worthy of a patch,
and may own a subsystem; and the master vets all code for
architectural coherence.  These roles vary by code base: I'm
apprentice of Plan 9, master of a 10-year-old build system.  I can
transfer some knowledge and skills, but still need to learn the
conventions and architecture before suggesting any dramatic (indeed,
noticeable) change.

Jason Catena



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 17:23             ` yy
  2009-08-07 18:50               ` Jason Catena
@ 2009-08-07 19:00               ` yy
  2009-08-08  4:16               ` 6o205zd02
  2 siblings, 0 replies; 18+ messages in thread
From: yy @ 2009-08-07 19:00 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

2009/8/7 yy <yiyu.jgl@gmail.com>:
> 2009/8/7 roger peppe <rogpeppe@gmail.com>:
>> the Include path.
>> contents of win buffers.
>> Undo/Redo history.
>
> Contents of all the taglines
>
> i have lost precious one-liners in column headers.
>
>> while i'm about it, there are a few other dump
>> features i'd like to see:
>> - automatic dumping every 30s or so in case of a crash.
>
> could this be done with a script?
>
>> - Dump would dump to the restored-from file rather than
>> $home/acme.dump by default.
>
> i did this once. unfortunately, i cannot find that code.
>

I forgot to mention that I lost the code because it got deprecated by
this rc function, which somebody else could find useful:

fn ad {	#acme dump
	dumpfile = $home/lib/dump/$1
	touch $dumpfile
	bind $dumpfile $home/acme.dump
	acme -l acme.dump
}


--
- yiyus || JGL . 4l77.com



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07  8:37 [9fans] Acme Configuration Aaron W. Hsu
  2009-08-07  9:20 ` Daniel Lyons
@ 2009-08-07 20:07 ` Uriel
  1 sibling, 0 replies; 18+ messages in thread
From: Uriel @ 2009-08-07 20:07 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

If all you want is to preserve the -a flag, add to your profile:

; fn a { acme -a; }

Problem solved.

uriel

P.S.: Admitedly this doesn't fix up the plumber, but once you have an
acme session the plumber will use it, and you can fix it up for the
plumber equally simply.

On Fri, Aug 7, 2009 at 10:37 AM, Aaron W. Hsu<arcfide@sacrideo.us> wrote:
> Other than a script to start acme with the -a option, is there some way to
> configure the start up option on Acme? I am thinking of the equivalent of a
> .exrc file or the like?
>
>        Aaron W. Hsu
>
> --
> Of all tyrannies, a tyranny sincerely exercised for the good of its victims
> may be the most oppressive. -- C. S. Lewis
>
>



^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [9fans] Acme Configuration
  2009-08-07 17:23             ` yy
  2009-08-07 18:50               ` Jason Catena
  2009-08-07 19:00               ` yy
@ 2009-08-08  4:16               ` 6o205zd02
  2 siblings, 0 replies; 18+ messages in thread
From: 6o205zd02 @ 2009-08-08  4:16 UTC (permalink / raw)
  To: 9fans

On Fri, 2009-08-07 at 19:23 +0200, yy yiyu.jgl-at-gmail.com |9fans|
wrote:
> 2009/8/7 roger peppe <rogpeppe@gmail.com>:
> > the Include path.
> > contents of win buffers.
> > Undo/Redo history.
>
> Contents of all the taglines
>
> i have lost precious one-liners in column headers.
>

Tag lines are preserved by Dump/Load in P9P acme
(http://code.swtch.com/plan9port/changeset/ec8f2649c141/).  I couldn't
live without out it.  I don't if/how changes are propagated from P9P to
plan9.

	- Peter Canning





^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2009-08-08  4:16 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-07  8:37 [9fans] Acme Configuration Aaron W. Hsu
2009-08-07  9:20 ` Daniel Lyons
2009-08-07  9:39   ` erik quanstrom
2009-08-07 13:34   ` Jason Catena
2009-08-07 13:50     ` Noah Evans
2009-08-07 14:02       ` roger peppe
2009-08-07 14:28         ` Noah Evans
2009-08-07 15:42           ` roger peppe
2009-08-07 15:48             ` erik quanstrom
2009-08-07 16:05             ` ron minnich
2009-08-07 16:54             ` Noah Evans
2009-08-07 17:07               ` Iruata Souza
2009-08-07 17:16                 ` erik quanstrom
2009-08-07 17:23             ` yy
2009-08-07 18:50               ` Jason Catena
2009-08-07 19:00               ` yy
2009-08-08  4:16               ` 6o205zd02
2009-08-07 20:07 ` Uriel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).