doc: fix after snaptools merge
This commit is contained in:
28
doc/functions/snap/example-firefox.nix
Normal file
28
doc/functions/snap/example-firefox.nix
Normal file
@@ -0,0 +1,28 @@
|
||||
let
|
||||
inherit (import <nixpkgs> { }) snapTools firefox;
|
||||
in snapTools.makeSnap {
|
||||
meta = {
|
||||
name = "nix-example-firefox";
|
||||
summary = firefox.meta.description;
|
||||
architectures = [ "amd64" ];
|
||||
apps.nix-example-firefox = {
|
||||
command = "${firefox}/bin/firefox";
|
||||
plugs = [
|
||||
"pulseaudio"
|
||||
"camera"
|
||||
"browser-support"
|
||||
"avahi-observe"
|
||||
"cups-control"
|
||||
"desktop"
|
||||
"desktop-legacy"
|
||||
"gsettings"
|
||||
"home"
|
||||
"network"
|
||||
"mount-observe"
|
||||
"removable-media"
|
||||
"x11"
|
||||
];
|
||||
};
|
||||
confinement = "strict";
|
||||
};
|
||||
}
|
||||
12
doc/functions/snap/example-hello.nix
Normal file
12
doc/functions/snap/example-hello.nix
Normal file
@@ -0,0 +1,12 @@
|
||||
let
|
||||
inherit (import <nixpkgs> { }) snapTools hello;
|
||||
in snapTools.makeSnap {
|
||||
meta = {
|
||||
name = "hello";
|
||||
summary = hello.meta.description;
|
||||
description = hello.meta.longDescription;
|
||||
architectures = [ "amd64" ];
|
||||
confinement = "strict";
|
||||
apps.hello.command = "${hello}/bin/hello";
|
||||
};
|
||||
}
|
||||
@@ -38,7 +38,7 @@
|
||||
<para>
|
||||
The following expression packages GNU Hello as a Snapcraft snap.
|
||||
</para>
|
||||
<programlisting><xi:include href="../../pkgs/build-support/snap/example-hello.nix" parse="text" /></programlisting>
|
||||
<programlisting><xi:include href="./snap/example-hello.nix" parse="text" /></programlisting>
|
||||
<para>
|
||||
<command>nix-build</command> this expression and install it with
|
||||
<command>snap install ./result --dangerous</command>.
|
||||
@@ -57,7 +57,7 @@
|
||||
example uses Firefox as an example, because it is one of the most
|
||||
complicated programs we could package.
|
||||
</para>
|
||||
<programlisting><xi:include href="../../pkgs/build-support/snap/example-firefox.nix" parse="text" /></programlisting>
|
||||
<programlisting><xi:include href="./snap/example-firefox.nix" parse="text" /></programlisting>
|
||||
<para>
|
||||
<command>nix-build</command> this expression and install it with
|
||||
<command>snap install ./result --dangerous</command>.
|
||||
|
||||
Reference in New Issue
Block a user