123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162 |
- # GuixSD Configuration \
- for merlin.browniehive.net
- Be aware of silly commit messages. Also, be aware that notabug removes strings inside angle brackets '<' so names from the irc log is snipped out, but they are there... :P
- # TODO
- SHEPHERD SERVICES!
- - Mcron: check and fix missing /var/run/tor. And check for battery - launch i3nagbar.
- - [DONE-ish] Fix battery alert using i3-nagbar. Y U NO Do wat I want?
- - rottlog? logrot?
- - Check and look through others/pkill9-desktop-config.scm
- - Send patch for norwegian dict
- - change or fix "build system" Now is a disaster of manual operations and failing scripts.
- - linode;
- - gvfs/fuser for usb and mmc;
- - wkhtmltopdf(.org)
- - BORG BACKUP: Almost done, need somewhere to backup to.
- - VPN: merlin - linode - quercus
- - WWOFFLE? https://www.gedanken.org.uk/software/wwwoffle/README
- - fetchmail?
- # brhive
- - Check ./maintenance/hydra/berlin.scm and so on as servers
- - Check ./others/ng0-old-systems/guixsd/servers/{shadownet,mailserver,++}
- - Migrate to guixsd.
- - evaluate alternatives for linode
- - ?setup weeslack?: https://github.com/wee-slack/wee-slack
- - ipfs?
- - xmpp
- - ¿mail?
- - httpd
- - vpn!
- - mosh
- - whatever else is on linode now
- - Setup quercus! even though physical location is undecided atm.
- ## Hitpoints is dead
- Got our hands on a macbook, now called merlin.
- Look at the following for setup:
- https://medium.com/@philpl/arch-linux-running-on-my-macbook-2ea525ebefe3
- http://www.frankshin.com/macbook-air-62-2013-setting-it-up-with-archlinux/
- https://github.com/pandeiro/arch-on-air
- # Notes
- ## This is on inheritance (is this inheritance from guix or guile?) from the #guix IRC channel:
- [16:29:19] <thomassgn> snape: allright, that does the trick. quite cumbersome though, it keeps throwing these at me, resolving number 3 now... :)
- [16:29:32] * marusich has quit (Quit: Leaving)
- [16:30:08] <snape> thomassgn: as an alternative, you can just run "guix build <my-package>" in a shell
- [16:34:10] <thomassgn> hehe, yes. Or not really. 'guix build -f ./libreoffice.scm libreoffice' tells me it cannot build. how can I tell it to build this definition of package...?
- [16:34:50] <snape> you need to put it into GUIX_PACKAGE_PATH
- [16:35:36] <snape> thomassgn: see https://www.gnu.org/software/guix/manual/guix.html#Defining-Packages
- [16:35:50] <snape> if it's your own package file
- [16:36:06] <snape> if it's within the guix source, then guix build libreoffice should work
- [16:36:44] <thomassgn> ok. But how do I know which libreoffice it builds if I say guix package -i libreoffice? I'm just testing a few things, and would like to do just copy the file and test some changes...
- [16:37:16] <thomassgn> I guess I could start changing the names and so on in the package definition.
- [16:37:17] <snape> if you modify Guix's libreoffice definition and run: "guix build libreoffice", it will build the modified libreoffice
- [16:37:39] <thomassgn> but I'm not modifying in place
- [16:38:01] <efraim> GUIX_PACKAGE_PATH takes precedence over guix proper for leaf packages
- [16:38:16] <thomassgn> cause it's read only in my profile... :)
- [16:38:19] <thomassgn> Ah!
- [16:38:44] <snape> thomassgn: your custom libreoffice package should probably inherit Guix's one
- [16:39:17] * atw has joined #guix
- [16:39:18] <snape> so that you don't have to copy everything
- [16:39:23] <thomassgn> nice. So any package with duplicate variable-name in my GUIX_PACKAGE_PATH will always be chosen?! nice.
- [16:39:39] <snape> yes, but it's probably clearer if the name is different
- [16:39:52] <snape> say, my-libreoffice
- [16:39:52] <thomassgn> Yes, I don't entirely understand inheritance though :P I'm a bit slow :)
- [16:40:16] <snape> you're not slow, it takes time ;)
- [16:41:50] <snape> thomassgn: there are a few package inheritance examples in the Guix source. You can grep "inherit" in /gnu/packages/ to see them.
- [16:42:45] <thomassgn> cool, I'll have a look. I've used it once in a simple thing I mostly copied.
- [16:43:05] <snape> also, things in GUIX_PACKAGE_PATH need to be valid Guile modules
- [16:43:46] <rekado> inheritance is a way to avoid duplication.
- [16:43:46] <resh> https://thepasteb.in/p/76hE6RvkK2DHV
- [16:44:03] <thomassgn> hehe, yes. I keep getting warnings from guix commands when I'm fiddling with somethings in there.
- [16:44:05] <rekado> a package can inherit all fields from another package.
- [16:44:19] <rekado> you can then override individual fields without having to specify others.
- [16:44:23] * atw has quit (Ping timeout: 260 seconds)
- [16:44:46] <roptat> resh: is the tarball in /tmp?
- [16:44:46] <rekado> resh: where is the tar.xz file?
- [16:45:07] <thomassgn> ah, but if I specify parts of a field will it append it to contents of the previous? or discard the previous?
- [16:45:15] <thomassgn> previous=inherited
- [16:45:24] <roptat> discard
- [16:45:27] <thomassgn> right
- [16:45:56] <roptat> but you can get the value by using (package-<field-name> libreoffice)
- [16:46:14] <resh> roptat and rekado not inside any directory ... installed without cd to any directory
- [16:47:03] <rekado> resh: so it might still be in your home directory then.
- [16:47:08] <thomassgn> So if I just want to add something I have to copy the contents of the inherited field into the new def.? uh, sorry, what did you mean with (package-<field-name> libreoffice)? I ould just go read the docs ofc.
- [16:47:25] <thomassgn> roptat: ^^
- [16:47:39] <rekado> thomassgn: (package-synopsis libreoffice) gives you the synopsis of the libreoffice package, for example.
- [16:47:51] <rekado> thomassgn: (package-inputs libreoffice) gives you the inputs.
- [16:47:59] <roptat> for instance to add an input you would write (inputs `(("some-package" ,some-package) ,@(package-inputs libreoffice)))
- [16:48:18] <roptat> with enough parenthesis
- [16:48:48] <thomassgn> haha, Nice. Thanks :)
- [16:49:08] <rekado> i.e. the inputs field has a quasi-quoted list with the list ("some-package" ,some-package) followed by the items in the inputs field of the libreoffice package.
- ## And from guix mailing list about environments "permanence":
- > Hello, I've been using guix `environment -l env.scm` to work on
- > different programming projects on my laptop.
- > The problem is: When I do guix pull or gc, these environments might get
- > lost, and when I'm on the train with no network and run `guix
- > environment` it will try to graft/rebuild/whatever, which requires an
- > internet connection, instead of just opening the last working environment.
- > So I can't work on my projects until I get back online.
- To protect your environment from GC, you can use ‘guix environment
- --root’: it register a “garbage collector root” for your environment as
- a symlink, which means your environment won’t be GC’d unless you remove
- that symlink.
- To prevent your environment from being updated even if you ran ‘guix
- pull’ in the meantime, you can use a separate profile. For instance,
- you can create a ‘dev’ profile for your development environment:
- guix package -p dev -i gcc-toolchain make
- and then whenever you want to “enter” that profile, do:
- . ./dev/etc/profile
- And of course you can have as many profiles as you want.
- ## And from IRC on commit messages, emacs and yasnippets
- [09:44:52] <thomassgn> Hey, I've been fixing the package definitions I sent in the other day. I'm writing the commitmessage now, but after reading the gnu changelog standards I have a few questions: My current commit message looks like "* gnu/packages/xdisorg.scm (screen-message): Add package definition" Should I add more explanation? and from before I'm used to putting just 68 characters on the first line no punctuation and then
- [09:44:54] <thomassgn> blank line before any more descritpion, but the gnu standards seem to say differently. is that right?
- [09:47:45] <roptat> thomassgn: it should be "* gnu/packages/xdisorg.scm (screen-message): New variable."
- [09:47:57] <roptat> see other commit messages for examples
- [09:48:43] <thomassgn> roptat: ah, I've tried looking at other commits and can't see any adding packages. I'm doing something wrong, yes.
- [09:49:12] <rekado> I want to build “axoloti-patcher” but the patch for “axoloti-libusb” no longer applies. So I updated the patch, but Guix still insists on applying the old version of the patch.
- [09:49:19] <rekado> What am I doing wrong?
- [10:09:07] <roptat> thomassgn: I think I confused you: the message should be "gnu: Add screen-message", a blank line and then "* gnu/packages/xdisorg.scm (screen-message): New variable.""
- [10:09:47] <roptat> and don't sign-off your own patch
- [10:09:52] <snape> with a '.' after "Add screen-message" :-)
- [10:16:20] <thomassgn> derp. ok, sent them allready. these guidelines are too complex/confusing for me it seems.
- [10:16:54] <thomassgn> thanks for pointing it out though, next commit message will be a bit better.
- [10:18:06] <rekado> thomassgn: if you’re using Emacs + magit you may find our commit message snippets useful.
- [10:18:22] <rekado> they are in etc/snippets and can be used with yasnippet.
- [10:18:57] <rekado> I only type “add” hit TAB and it expands to the right text for adding a new package.
- [10:18:57] <thomassgn> rekado: cool, is there an easy way to add them? Ah, yasnippet: the plugin I've had since the start, but never used... :P
- [10:19:07] <thomassgn> awesome
- [10:19:24] <rekado> thomassgn: take a look at the contributing manual section.
- [10:19:36] <rekado> it tells you how to set this up.
- [10:22:32] <thomassgn> you mean the section "the perfect setup"?
- [10:22:57] <rekado> yes, that’s the one
- [10:23:43] <rekado> BTW my patch problem was due to GUIX_PACKAGE_PATH, which included a duplicate package definition
- [10:23:44] <thomassgn> cause it assumes that I'm working in a git checkout of the guix source, which I don't. I remember I couldn't make it work, too much confusion between my running system and the git checkout...
- [10:24:21] <rekado> you can also just copy the snippets to some other directory and refer to them.
- [10:24:32] <rekado> you don’t need to wrok from a git checkout to use the snippets.
- [10:24:45] <rekado> (but I do wonder how you submit patches when you don’t use a git checkout.)
- [10:25:08] <thomassgn> I understand a lot more now, compared to last time I tried this. So I'll probably try again soon.
- [10:27:01] <wigust> thomassgn: Also “C-x v l runs the command vc-print-log” in file you want to commit helps with a commit message.
- [10:27:09] <thomassgn> oh I do use git, but I have my own repo where I write and test package defs. and then I copy the defs over to the guix src checkout and make the patch. Yes it's tedious, but I understand what's happening and I don't have errors I don't understand flowing around... :P
- [10:27:46] <thomassgn> cool, thanks wigust and rekado
|