unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: "Cássio Tavares" <cassio.ufg@gmail.com>
To: Guix Help Mailing List <help-guix@gnu.org>
Subject: Packaging baby-steps
Date: Wed, 27 Apr 2022 20:05:00 +0000	[thread overview]
Message-ID: <CAJTCCxOT2VG2B3M-sBAxtFXHkGd4f=3xakJBK7YXxnyJw4O5iA@mail.gmail.com> (raw)

Hello!

I'm new to Guix, and I chose to use it for the principles of it
(linux-libre and such), but against a better judgement of my technical
incompetence. So.

A lot of things I was used to in more mainstream distros are not packaged
here and, after reading the manual and learning about how I could write my
own packages, and with `guix import` for short-cut, I decided to give it a
try. Then another. Then another — in all of them I failed miserably, and
couldn't make any sense of the log files…

I let it go for a while, but then I thought that some packages should be
easier to write than the ones I tried. So, I started looking around for
what I could do, and I realised: there are no plugin managers for neovim.
Then I went to GitHub, and looked at `*packer.nvim*
<https://github.com/wbthomason/packer.nvim>`, and… …is it feasible? — this
is how `*packer.nvim*` is supposed to be installed on regular, imperative
distros:

*Step One:* issue this command:


*git clone --depth 1 https://github.com/wbthomason/packer.nvim\
<https://github.com/wbthomason/packer.nvim\>
~/.local/share/nvim/site/pack/packer/start/packer.nvim*


*Step Two:* write a `*/path/to/neovim/plugins/lua/plugins.lua*` that
contains:

*-- Only required if you have packer configured as `opt`*





*vim.cmd [[packadd packer.nvim]]return
require('packer').startup(function()  -- Packer can manage itself  use
'wbthomason/packer.nvim'*

*  -- Configure other plugins*

  *…*
*end)*



*Step three:* include this line —  `*lua require('plugins')*` — in the file
`*init.vim*`, wherever it is.

*My questions:*

   1. *Step one* seems to be just a simple file download to an appropriate
   directory — is that assessment correct?
   2. If so, would it be hard to generalize this so that it can be
   installed either system-wide or per-user? I guess there is a Guix idiomatic
   way to accomplish what the above git command is doing, right?
   3. *Step two*, I imagine, should be easy if there isn't already a `
   *plugin.lua*` file, right? What if there is?
   4. Is it acceptable if the installation process doesn't look into the
   plugins directory-tree to try and automatically create entries for them in
   `*plugin.lua*`?
   5. Also, in *Step two*, the first line in `*plugin.lua*` is required
   only if a certain condition is met. Is it OK to leave it there if the
   condition is not met?
   6. The problems in *Step three* seem to be the same as in *Step two*.
   Except that maybe it could be assumed that, since `*neovim*` is a
   dependency, the file `*init.vim*` would necessarily exist?
   7. From what I could tell from `*packer.nvim*`'s repo, the only
   dependency is on neovim version 0.5 or later — is there anything else I
   would need to work on or check out?

I will be grateful to anyone who helps me to write my first package...
Regards,
Cássio
-----
Faculdade de Letras - UFG
*“*
*Ou a gente se Raôni, ou a gente se Sting**”*

             reply	other threads:[~2022-04-27 20:06 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-27 20:05 Cássio Tavares [this message]
  -- strict thread matches above, loose matches on Subject: below --
2022-05-10  1:00 Packaging baby-steps Antlers

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

  List information: https://guix.gnu.org/

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

  git send-email \
    --in-reply-to='CAJTCCxOT2VG2B3M-sBAxtFXHkGd4f=3xakJBK7YXxnyJw4O5iA@mail.gmail.com' \
    --to=cassio.ufg@gmail.com \
    --cc=help-guix@gnu.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.
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 read-only IMAP folder(s) and NNTP newsgroup(s).