zsh-workers
 help / color / mirror / code / Atom feed
From: Sebastian Gniazdowski <sgniazdowski@gmail.com>
To: dana <dana@dana.is>
Cc: Daniel Shahaf <d.s@daniel.shahaf.name>,
	Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: Official plugin manager?
Date: Fri, 3 Jan 2020 03:43:27 +0100	[thread overview]
Message-ID: <CAKc7PVCHvbQ6YbTj5w6nZ=ZZHZoOeKF3XnHUy5+Sx48oy3U+iA@mail.gmail.com> (raw)
In-Reply-To: <186D63AE-2F2A-41C3-9E09-CEE0714E2B7F@dana.is>

On Fri, 3 Jan 2020 at 02:34, dana <dana@dana.is> wrote:
>
> Is the problem you're trying to solve 'people don't know which plug-in manager
> to use' or 'people don't know how to configure zsh so they just install OMZ'?
> The one you're describing here is the former.

To be able to configure Zsh people need a p-m (to be able to use the
sourcables like @bindkeys, @history, etc. – that would be doing the
actual configuration). So it's not A vs. B, but A -> B, where A is
"people need a p-m / sourcables" and B is "people are able to
configure Zsh".

> Once they *have* a plug-in
> manager, they can install whatever they want, and they seem to want OMZ. (It's
> even the first example in the Antigen documentation...)

Well OK, however, there is the obstacle of having a choice. I think
that this is also promoting OMZ: "so many frameworks / p-m out there
and it's so difficult to choose? well, I better stick to 1500
contributors-backed Oh My Zsh".

> On 2 Jan 2020, at 18:25, Sebastian Gniazdowski <sgniazdowski@gmail.com> wrote:
> > OK, however, the sourcables-backend to zsh-newuser-install is IMO
> > needed first. Then the install function could offer to append:
> >
> > zsh-pm pick=nodups.zsh param='size -> 10000' @history
> >
> > to the zshrc.
>
> You've responded to me saying 'instead of providing fine control over the
> profile set-up it could simply give them some good defaults' with 'OK, but
> first we need to add more complexity in order to provide finer control over
> the profile set-up'

Well yes, because I suspect that there will be a rough time on
establishing what the defaults are supposed to be. And also, the
sourcables are a new method of providing the snippets with the
defaults. With them, there could have been a few variants of each
plugin like @bindkeys, which would ease the problem of establishing
the defaults.

> Also, your example command is about 20 characters longer, and significantly
> harder to read or to transfer into a broader understanding of how the shell
> configuration works, than just setting it the normal way. How would this
> address the difficulty me and Roman described re: not understanding the
> implications of the wizard?

I thought about the @history / nodups.zsh to be something like:

HISTFILE=${file:-~/.zhistory}
HISTFILE=${~HISTFILE}
HISTSIZE=${size:-10000}
SAVEHIST=$HISTSIZE
setopt hist_ignore_dups
setopt inc_append_history hist_fcntl_lock

# Default-off options
setopt ${all+histi_gnore_all_dups}   ${find+hist_find_no_dups}
setopt ${space+hist_ignore_space}   ${copy+hist_save_by_copy}
setopt ${verify+hist_verify}   ${clobber+hist_allow_clobber}

# Default-on options
setopt ${nolex-hist_lex_words}  ${noblanks-histreduceblanks}

These are not all history options considered. So the loading of the
sourceable would have been:

zsh-pm pick=nodups.zsh @history
zsh-pm pick=nodups.zsh param'size -> 2000; file -> ~/.zhist' @history
zsh-pm pick=nodups.zsh param'copy; all; nolex' @history

And this would allow elastic providing of defaults with an additional
layer – the sourceable file. Normally the file contents would have to
be hardcoded into the newuser install script (plus the not exactly
solvable problem of the option modifiers). Here, only a few keywords
will have to be remembered in the installer and then the sourceable
could be freely edited.

The example sourceable script shows also how difficult will it be to
come up with the non-elastic default settings for history.

-- 
Sebastian Gniazdowski
News: https://twitter.com/ZdharmaI
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zplugin
Blog: http://zdharma.org

  reply	other threads:[~2020-01-03  2:44 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-02  3:17 Sebastian Gniazdowski
2020-01-02  4:28 ` Eric Cook
2020-01-02 11:03 ` Daniel Shahaf
2020-01-02 11:37   ` Sebastian Gniazdowski
2020-01-02 11:55     ` Sebastian Gniazdowski
2020-01-02 21:30     ` dana
2020-01-03  0:25       ` Sebastian Gniazdowski
2020-01-03  1:36         ` dana
2020-01-03  2:43           ` Sebastian Gniazdowski [this message]
2020-01-03  2:45           ` Bart Schaefer
2020-01-03  3:26             ` dana
2020-01-03  5:13               ` Sebastian Gniazdowski
2020-01-03 15:00               ` Peter Stephenson
2020-01-03 20:48                 ` Daniel Shahaf
2020-01-03 21:51                   ` Roman Perepelitsa
2020-01-03 22:06                     ` Daniel Shahaf
2020-01-03 22:26                       ` Bart Schaefer
2020-01-03 22:37                       ` Roman Perepelitsa
2020-01-04  0:42                         ` dana
2020-01-04  1:06                           ` Daniel Shahaf
2020-01-04 15:46                           ` Roman Perepelitsa
2020-01-04 16:27                             ` Daniel Shahaf
2020-01-04 16:41                               ` Roman Perepelitsa
2020-01-04 17:35                                 ` Daniel Shahaf
2020-01-04 17:42                                   ` Roman Perepelitsa
2020-01-04 17:11                             ` Bart Schaefer
2020-01-05 10:40                               ` Oliver Kiddle
2020-01-06 17:47                   ` Leah Neukirchen
2020-01-03 11:15             ` Oliver Kiddle
2020-01-04  5:16               ` Sebastian Gniazdowski
2020-01-04  6:00                 ` Sebastian Gniazdowski
2020-01-02 12:00   ` Roman Perepelitsa
2020-01-02 12:21     ` Sebastian Gniazdowski
2020-01-02 12:27       ` Roman Perepelitsa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAKc7PVCHvbQ6YbTj5w6nZ=ZZHZoOeKF3XnHUy5+Sx48oy3U+iA@mail.gmail.com' \
    --to=sgniazdowski@gmail.com \
    --cc=d.s@daniel.shahaf.name \
    --cc=dana@dana.is \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

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).