Code academy: icons

2016-01-29 Thread Edward K. Ream
During our conference call, someone asked whether nodes may have more than 
one icon.  Indeed they can.

For example, running this script will insert three icons. Running the 
script again will insert three more.  You can delete the icons using the 
delete-node-icons command. I'm having trouble deleting icons 
programmatically.  I'm investigating.

table = (
'edittrash.png',
'connect_no.png',
'error.png',
)
for icon in table:
fn = g.os_path_finalize_join(g.app.loadDir,
'..', 'Icons', 'Tango', '16x16', 'status', icon)
if g.os_path_exists(fn):
c.editCommands.insertIconFromFile(path=fn)

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Leo's code academy: how to do cool things easily

2016-01-29 Thread Kent Tenney
Any interest in uA default format being text instead of pickle?

On Thu, Jan 28, 2016 at 8:41 PM, Edward K. Ream  wrote:
> Richard, Don, Rob and I had an excellent conference call today. Great things
> are coming, based on tagging and uA's.
>
> The discussion highlighted a big hole in Leo's documentation. We need a
> summary of how to do cool things easily with Leo.  This will allow people to
> dream bigger.
>
> Here is a quick list topics for the code academy.  Mos can already be done
> easy, if you know where to look.  Some may require a few new lines in Leo's
> core. These topics should also be included in Leo's cheat sheet, or
> somewhere similar.
>
> uA's
>
> They are crucial to flexible data management. uA's can associate arbitrary
> data with any vnode or position, as describe here.
>
> Everyone needs to know how to get, set and search uA's.  You can get and set
> uA's with v.u. Just a few lines of code will search the entire outline for
> all nodes/positions having a given uA.
>
> Quick additions to Leo's core:
> - Define the p.u property, so code can do p.u instead of p.v.u.
> - Possibly make the api for uA's more convenient.
>
> A more ambitious addition: Define a gui interface for uA's.
>
> Other topics
>
> - Clones: making and deleting them. Clones are cheap to create!
> - How to create new panes in the log window, and how to put cool stuff in
> them.
> - How to hoist outlines programmatically.
> - How to write a plugin so it can respond to events.
> - How to create new panes in Leo's window with Terry's free_layout and
> nested_splitter plugins.  In essence, these plugin are part of Leo's core.
> - How to put multiple icons in a single headline.  This may be possible
> already.  If not it would require just a few lines of code in Leo's core.
>
> We discussed the so-called Easter-Egg interface to create new panes this
> from the gui, but a summary of how to do this programmatically is needed.
> Note: it's possible to save the layout so that Leo will restore it when Leo
> starts up the next time.
>
> - How to change what is shown in the outline pane.  Chapters and hoists
> exploit existing capabilities.  If need be, more could be added with just a
> few lines of code in Leo's main outline redrawing code.
>
> New directions
>
> Putting all this together, we all agreed that being able to make uA's
> visible somehow would give Leo many of the cool features of the ECCO
> outliner. We envisage a uA tab in the outline pane that would allow the user
> to:
>
> - See all and only nodes with given attributes.  This is similar to Leo's
> clone-find-all (or clone-find-all-flattened) commands, combined with
> something like a hoist.
>
> - List all such nodes in the uA pane, similar to the Nav Pane (Quicksearch
> plugin), so that clicking on a node would select the node in the entire
> outline, with only ancestors of the selected node expanded.  Pretty easy to
> do.  Alternatively, perhaps some  tag (uA) oriented features can be added to
> existing plugins.
>
> Conclusions
>
> I expect that we can do really great things with Leo in just a few weeks.
>
> Discussions of how to do practical tasks may be missing from the current
> documentation.  Neophytes have to read between too many lines.  A list of
> easily done programming tasks will help develop a larger cadre of
> developers.
>
> Edward
>
> --
> You received this message because you are subscribed to the Google Groups
> "leo-editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to leo-editor+unsubscr...@googlegroups.com.
> To post to this group, send email to leo-editor@googlegroups.com.
> Visit this group at https://groups.google.com/group/leo-editor.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Leo's code academy: how to do cool things easily

2016-01-29 Thread Edward K. Ream
On Fri, Jan 29, 2016 at 6:16 AM, Edward K. Ream  wrote:

> On Fri, Jan 29, 2016 at 5:31 AM, Kent Tenney  wrote:
>
>> Any interest in uA default format being text instead of pickle?
>>
>
> ​No.
>

​The documentation  should suggest using str_ keys unless pickling is
essential. This rule of them should apply to any new plugin that the code
academy creates.

I wonder. Is it possible to get the effect of what you suggest without
actually changing Leo's file format?  Some convention like only pickling
keys that started with pickle_.  At present, there is no p.u property, so
maybe p.u could do the switcheroo.

But no, that's a terrible idea. It would lead to confusion and broken
plugins. The switcheroo would have to be bulletproof, but it can't be.  v.u
already exists, so changing v.u would break plugins.  Bad things will
happen long-term if p.u is different from p.v.u. Nobody, including me, is
going to remember that p.u != p.v.u.  So there's no way.

In short, the documentation should just encourage the use of str_ keys.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Abbreviations

2016-01-29 Thread Kent Tenney
I'm finding Leo's abbreviations to be really wonderful, sort
of 'active templates'

The abbrev-read and abbrev-write commands are great,
abbrev definitions should be able to exist outside Leo
files in the spirit of DRY.

The syntax used by the read/write commands and the
syntax used within a
@data abbreviations
node is different, when written to file, each abbrev consists
of a single line.

I think it would be great if the abbrev-read and abbrev-write
files could look like the defs in a @data node.

Thanks,
Kent

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Leo's code academy: how to do cool things easily

2016-01-29 Thread Edward K. Ream
On Fri, Jan 29, 2016 at 5:31 AM, Kent Tenney  wrote:

> Any interest in uA default format being text instead of pickle?
>

​No.

The code that reads and writes uA's to .leo files is mind-boggling complex.
Any change would constitute a major change to Leo's file format.  The
benefits are tiny because of the str_ convention, discussed here

:

Leo does *not* pickle members of inner dictionaries whose name (key)
starts with str_. The values of such members should be a Python string.
This convention allows strings to appear in .leo files in a more
readable
format.

Any plugin can use str_ keys in their inner dictionaries, even if they do
not do so at present.  Transitioning to string keys is easy. The plugin
would first look for new-style keys (starting with str). If none are found,
the plugin could look for old keys.  Also, the plugin could look for a
str_version key, and use the presence or absence of the key to look for
old-style or new-style keys.

Automatic pickling of uA's has some advantages. Any object that can be
pickled can be "reconstituted" automatically.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Code academy: icons

2016-01-29 Thread Edward K. Ream
On Fri, Jan 29, 2016 at 9:08 AM, Edward K. Ream  wrote:

You can delete the icons using the delete-node-icons command.
>

​With a minor change to Leo's core, it is now easy to delete the icons of
the node at position p:

c.editCommands.deleteNodeIcons(p=p)

As Terry points out, other code works too, but the above is the clearest,
imo, because it is higher level and more descriptive.

EKR

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Code academy: icons

2016-01-29 Thread Edward K. Ream
On Fri, Jan 29, 2016 at 10:01 AM, Edward K. Ream 
wrote:

​
​> ​
I would have thought that calling c.editCommands.deleteNodeIcons() should
work.

​Never mind.  I made several errors.

I changed deleteNodeIcons by adding a p keyword argument so that it could
work on any node, not just c.p.  But I passed p==p to it rather than p=p.
Heh.  It's a new kind of error for me...

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Code Academy: real Leo programmers use git

2016-01-29 Thread Edward K. Ream
If you are going to do interesting work on Leo and its plugins, you should 
be using Leo’s latest sources  
from GitHub  using git . 
Once git is installed, getting the latest version of Leo is easy:

git clone https://github.com/leo-editor/leo-editor.git

Once you have done that, you can get the latest sources with:

git pull

Git is great in tracking history and reverting unwanted changes. And it has 
many other benefits.

I've been wondering when to say this, but recent developments have forced 
my hand.  Today, as the result of our Code Academy discussion, I have added 
the p.u property and a keyword arg to c.editCommands.deleteNodeIcons.  If 
you don't use git you will quickly get out of the loop.

Although git is unique behind the scenes, using git is very similar to 
using bzr or hg or any other SCCS.  To change Leo, you add files, you 
commit files, and you push files.  That's about it.

I'll be happy to answer any git-related questions here.  Again, I *strongly* 
encourage all would-be Leo programmers to use Leo's git repo.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Code academy: icons

2016-01-29 Thread 'Terry Brown' via leo-editor



 From: Edward K. Ream 
 To: leo-editor  
 Sent: Friday, January 29, 2016 9:08 AM
 Subject: Code academy: icons
   
During our conference call, someone asked whether nodes may have more than one 
icon.  Indeed they can.

For example, running this script will insert three icons. Running the script 
again will insert three more.  You can delete the icons using the 
delete-node-icons command. I'm having trouble deleting icons programmatically.  
I'm investigating.


c.editCommands.setIconList(p, [])c.redraw()
If you don't want to delete them all:icons = c.editCommands.getIconList(p)icons 
= [i for i in icons if ]c.editCommands.setIconList(p, 
icons)

also, add a True param. at end of setIconList call to mark node dirty (changed, 
save required) if desired.
Cheers -Terry


table = (
    'edittrash.png',
    'connect_no.png',
    'error.png',
)
for icon in table:
    fn = g.os_path_finalize_join(g.app.loadDir,
        '..', 'Icons', 'Tango', '16x16', 'status', icon)
    if g.os_path_exists(fn):
        c.editCommands.insertIconFromFile(path=fn)

Edward
-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


   

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Leo's code academy: uA's and the new p.u property

2016-01-29 Thread Edward K. Ream
A recent rev added the p.u property, which you can think of as a synonym 
for p.v.unknownAttributes on *both* sides of an assignment.

The example in Leo's documentation for access uA's is *way *too 
complicated. In fact, the following suffices to set the 'n' attribute for 
test_plugin:

plugin_name = 'test_plugin'
d = p.u.get(plugin_name,{})
d ['n'] = 8
p.u [plugin_name] = d

p.u is the *outer* dictionary. p.u.get.(plugin_name, {}) is the inner 
dictionary. The last line is all that is needed to update the outer 
dictionary!

It is *very* easy to search for particular uA's. The following script 
prints all the keys in the outer-level uA dictionaries:

for p in c.all_unique_positions():
if p.u:
print(p.h, sorted(p.u.keys()))

This is a typical usage of Leo's generators 
.  Generators 
visit each position (or node) quickly. Even if you aren't going to program 
much, you should be aware of how easy it is to get and set the data in each 
node. In fact, now would be a great time to read Leo's Scripting Tutorial 
 again :-) This will allow 
you to "dream bigger" with Leo.

The following script creates a list of all positions having an icon, that 
is, an outer uA dict with a 'lineYOffset' key.

aList = [p.copy() for p in c.all_unique_positions() if 'lineYOffset' in p.u]
print('\n'.join([p.h for p in aList]))

Yes, the lineYOffset key is wonky and unhelpful, but it can't be changed 
now.  Hmm, maybe the code could support an an alternative clearer key, say 
str_core_icon.  Furthermore, the str_core_* keys should probably be 
reserved for Leo's core.

*Important*: If you don't understand these lines, *please *study Python's list 
comprehensions .  
They are incredibly useful. '\n'.join(aList) is a great idiom to know.  
str.join is one of python's most useful string methods 
. It 
converts between lists and strings.

Imo, Leo should have p.temp_u and v.temp_u properties, so that getting and 
setting temp uA's will be as easy as getting and setting uA's. I'll do this 
today.

These Code Academy threads are having an immediate impact.  Focusing on 
simple, practical tasks has revealed rough spots in both Leo's code and 
Leo's docs.

As always with the Code Academy, questions and comments are strongly 
encouraged. Make *sure* you understand the code examples in this post. They 
are the foundation for programming in Leo. 

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Code academy: icons

2016-01-29 Thread Edward K. Ream
On Fri, Jan 29, 2016 at 9:30 AM, 'Terry Brown' via leo-editor <
leo-editor@googlegroups.com> wrote:

​>> ​I'm having trouble deleting icons programmatically.  I'm
investigating.​

c.editCommands.setIconList(p, [])
> c.redraw()
>
> If you don't want to delete them all:
>


> icons = c.editCommands.getIconList(p)
> icons = [i for i in icons if ]
>

​Thanks for this.  ​However, I would have thought that calling
c.editCommands.deleteNodeIcons() should work.  Don't see why not, since
delete-node-icons does work.  Any ideas?

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Code Academy: real Leo programmers use git

2016-01-29 Thread Largo84
Terry, that seems like a terrific idea. Can't think of why it wouldn't work.

Rob...

On Friday, January 29, 2016 at 3:10:19 PM UTC-5, Terry Brown wrote:
>
> Git *users* can create gists, like https://gist.github.com/tbnorth/6165576
>
> But https://github.com/leo-editor is a GitHub organization, not user, so 
> it doesn't have gists, instead I made a separate repo. all members of 
> leo-editor can push to: https://github.com/leo-editor/snippets
> I'd vote for that.  There's more junk, um, I mean invaluable and 
> educational examples :-),  laying around at the top level than there should 
> be, but as long it doesn't get worse and people (myself included) remember 
> to put things in subfolders going forward, I think it will be ok.
>
> Does that seem like a workable option to you?  If it needed to look 
> prettier, we could use github pages to make an index or something.
>
> BTW, anyone know how to stop google-groups hiding my email address (
> terry_...@yahoo.com )? I can't find the setting.
>
> Cheers -Terry
>
> --
> *From:* Largo84 
> *To:* leo-editor  
> *Sent:* Friday, January 29, 2016 1:57 PM
> *Subject:* Re: Code Academy: real Leo programmers use git
>
> This is all great stuff. Yes, been using Git for a while now to stay 
> current on the code base. I've often wondered if there's also an easier way 
> to share code snippets and scripts. There's Leo wiki 
>  that would be ideal for that, but it 
> hasn't been edited in over 4 years. Is that something that can be revived?
>
> Rob...
>
> On Friday, January 29, 2016 at 11:37:59 AM UTC-5, Edward K. Ream wrote:
>
> If you are going to do interesting work on Leo and its plugins, you should 
> be using Leo’s latest sources  
> from GitHub  using git 
> . Once git is installed, getting the latest version 
> of Leo is easy:
>
> git clone https://github.com/leo-editor/ leo-editor.git 
> 
>
> Once you have done that, you can get the latest sources with:
>
> git pull
>
> Git is great in tracking history and reverting unwanted changes. And it 
> has many other benefits.
>
> I've been wondering when to say this, but recent developments have forced 
> my hand.  Today, as the result of our Code Academy discussion, I have added 
> the p.u property and a keyword arg to c.editCommands. deleteNodeIcons.  If 
> you don't use git you will quickly get out of the loop.
>
> Although git is unique behind the scenes, using git is very similar to 
> using bzr or hg or any other SCCS.  To change Leo, you add files, you 
> commit files, and you push files.  That's about it.
>
> I'll be happy to answer any git-related questions here.  Again, I 
> *strongly* encourage all would-be Leo programmers to use Leo's git repo.
>
> Edward
>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "leo-editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to leo-editor+...@googlegroups.com .
> To post to this group, send email to leo-e...@googlegroups.com 
> .
> Visit this group at https://groups.google.com/group/leo-editor.
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Leo's code academy: how to do cool things easily

2016-01-29 Thread 'Terry Brown' via leo-editor
On Thu, 28 Jan 2016 18:41:09 -0800 (PST)
"Edward K. Ream"  wrote:

> We discussed the so-called Easter-Egg interface to create new panes
> this from the gui, but a summary of how to do this programmatically
> is needed.

I've given a couple of examples of how to do this, let's see...

https://github.com/leo-editor/snippets/blob/master/examples/demo_widget.py

has comments,

https://gist.github.com/tbnorth/6165576

is another one that adds a web-browser pane, as written it opens it in
a separate window, which is part of the free_layout system.

Cheers -Terry

> *Note*: it's possible to save the layout so that Leo will
> restore it when Leo starts up the next time.

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Code Academy: real Leo programmers use git

2016-01-29 Thread Largo84
This is all great stuff. Yes, been using Git for a while now to stay 
current on the code base. I've often wondered if there's also an easier way 
to share code snippets and scripts. There's Leo wiki 
 that would be ideal for that, but it hasn't 
been edited in over 4 years. Is that something that can be revived?

Rob...

On Friday, January 29, 2016 at 11:37:59 AM UTC-5, Edward K. Ream wrote:
>
> If you are going to do interesting work on Leo and its plugins, you should 
> be using Leo’s latest sources  
> from GitHub  using git 
> . Once git is installed, getting the latest version 
> of Leo is easy:
>
> git clone https://github.com/leo-editor/leo-editor.git
>
> Once you have done that, you can get the latest sources with:
>
> git pull
>
> Git is great in tracking history and reverting unwanted changes. And it 
> has many other benefits.
>
> I've been wondering when to say this, but recent developments have forced 
> my hand.  Today, as the result of our Code Academy discussion, I have added 
> the p.u property and a keyword arg to c.editCommands.deleteNodeIcons.  If 
> you don't use git you will quickly get out of the loop.
>
> Although git is unique behind the scenes, using git is very similar to 
> using bzr or hg or any other SCCS.  To change Leo, you add files, you 
> commit files, and you push files.  That's about it.
>
> I'll be happy to answer any git-related questions here.  Again, I 
> *strongly* encourage all would-be Leo programmers to use Leo's git repo.
>
> Edward
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Code Academy: real Leo programmers use git

2016-01-29 Thread 'Terry Brown' via leo-editor
Git *users* can create gists, like https://gist.github.com/tbnorth/6165576
But https://github.com/leo-editor is a GitHub organization, not user, so it 
doesn't have gists, instead I made a separate repo. all members of leo-editor 
can push to: https://github.com/leo-editor/snippetsI'd vote for that.  There's 
more junk, um, I mean invaluable and educational examples :-),  laying around 
at the top level than there should be, but as long it doesn't get worse and 
people (myself included) remember to put things in subfolders going forward, I 
think it will be ok.
Does that seem like a workable option to you?  If it needed to look prettier, 
we could use github pages to make an index or something.
BTW, anyone know how to stop google-groups hiding my email address 
(terry_n_br...@yahoo.com)? I can't find the setting.
Cheers -Terry
 
  From: Largo84 
 To: leo-editor  
 Sent: Friday, January 29, 2016 1:57 PM
 Subject: Re: Code Academy: real Leo programmers use git
   
This is all great stuff. Yes, been using Git for a while now to stay current on 
the code base. I've often wondered if there's also an easier way to share code 
snippets and scripts. There's Leo wiki that would be ideal for that, but it 
hasn't been edited in over 4 years. Is that something that can be revived?
Rob...

On Friday, January 29, 2016 at 11:37:59 AM UTC-5, Edward K. Ream wrote:
If you are going to do interesting work on Leo and its plugins, you should be 
using Leo’s latest sources from GitHub using git. Once git is installed, 
getting the latest version of Leo is easy:

git clone https://github.com/leo-editor/ leo-editor.git
Once you have done that, you can get the latest sources with:

git pull
Git is great in tracking history and reverting unwanted changes. And it has 
many other benefits.

I've been wondering when to say this, but recent developments have forced my 
hand.  Today, as the result of our Code Academy discussion, I have added the 
p.u property and a keyword arg to c.editCommands. deleteNodeIcons.  If you 
don't use git you will quickly get out of the loop.

Although git is unique behind the scenes, using git is very similar to using 
bzr or hg or any other SCCS.  To change Leo, you add files, you commit files, 
and you push files.  That's about it.

I'll be happy to answer any git-related questions here.  Again, I strongly 
encourage all would-be Leo programmers to use Leo's git repo.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


   

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.


Re: Code Academy: real Leo programmers use git

2016-01-29 Thread Ville M. Vainio
Note that github provides a direct way tn edit files on the website.

E.g. go to
https://github.com/leo-editor/snippets/blob/master/examples/rst-tutorial/myDocument.html.txt

and click the pen icon.

This also works for people without commit rights; you can edit a file and
create a pull request without ever installing git :).

On Fri, Jan 29, 2016 at 10:10 PM, 'Terry Brown' via leo-editor <
leo-editor@googlegroups.com> wrote:

> Git *users* can create gists, like https://gist.github.com/tbnorth/6165576
>
> But https://github.com/leo-editor is a GitHub organization, not user, so
> it doesn't have gists, instead I made a separate repo. all members of
> leo-editor can push to: https://github.com/leo-editor/snippets
> I'd vote for that.  There's more junk, um, I mean invaluable and
> educational examples :-),  laying around at the top level than there should
> be, but as long it doesn't get worse and people (myself included) remember
> to put things in subfolders going forward, I think it will be ok.
>
> Does that seem like a workable option to you?  If it needed to look
> prettier, we could use github pages to make an index or something.
>
> BTW, anyone know how to stop google-groups hiding my email address (
> terry_n_br...@yahoo.com)? I can't find the setting.
>
> Cheers -Terry
>
> --
> *From:* Largo84 
> *To:* leo-editor 
> *Sent:* Friday, January 29, 2016 1:57 PM
> *Subject:* Re: Code Academy: real Leo programmers use git
>
> This is all great stuff. Yes, been using Git for a while now to stay
> current on the code base. I've often wondered if there's also an easier way
> to share code snippets and scripts. There's Leo wiki
>  that would be ideal for that, but it
> hasn't been edited in over 4 years. Is that something that can be revived?
>
> Rob...
>
> On Friday, January 29, 2016 at 11:37:59 AM UTC-5, Edward K. Ream wrote:
>
> If you are going to do interesting work on Leo and its plugins, you should
> be using Leo’s latest sources 
> from GitHub  using git
> . Once git is installed, getting the latest version
> of Leo is easy:
>
> git clone https://github.com/leo-editor/ leo-editor.git
> 
>
> Once you have done that, you can get the latest sources with:
>
> git pull
>
> Git is great in tracking history and reverting unwanted changes. And it
> has many other benefits.
>
> I've been wondering when to say this, but recent developments have forced
> my hand.  Today, as the result of our Code Academy discussion, I have added
> the p.u property and a keyword arg to c.editCommands. deleteNodeIcons.  If
> you don't use git you will quickly get out of the loop.
>
> Although git is unique behind the scenes, using git is very similar to
> using bzr or hg or any other SCCS.  To change Leo, you add files, you
> commit files, and you push files.  That's about it.
>
> I'll be happy to answer any git-related questions here.  Again, I
> *strongly* encourage all would-be Leo programmers to use Leo's git repo.
>
> Edward
>
> --
> You received this message because you are subscribed to the Google Groups
> "leo-editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to leo-editor+unsubscr...@googlegroups.com.
> To post to this group, send email to leo-editor@googlegroups.com.
> Visit this group at https://groups.google.com/group/leo-editor.
> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "leo-editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to leo-editor+unsubscr...@googlegroups.com.
> To post to this group, send email to leo-editor@googlegroups.com.
> Visit this group at https://groups.google.com/group/leo-editor.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.