Simple typst application
This commit is contained in:
1 parent
289f78804f
commit
2cdd388d66
3 files changed
+23
-2
No files matched your search
@@ -1 +1,2 @@
|
|||||||
result
|
result
|
||||||
|
*.pdf
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
description = "Using typst as 3rd party flake in devshell";
|
description = "Simple typst application";
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
flake-utils.url = "github:numtide/flake-utils";
|
flake-utils.url = "github:numtide/flake-utils";
|
||||||
@@ -14,7 +14,16 @@
|
|||||||
in
|
in
|
||||||
{
|
{
|
||||||
packages = {
|
packages = {
|
||||||
default = pkgs.hello;
|
default = pkgs.stdenv.mkDerivation {
|
||||||
|
name = "document";
|
||||||
|
src = ./.;
|
||||||
|
buildInputs = [typst];
|
||||||
|
buildPhase = "${pkgs.typst}/bin/typst compile main.typ main.pdf";
|
||||||
|
installPhase = ''
|
||||||
|
mkdir $out
|
||||||
|
mv main.pdf $out
|
||||||
|
'';
|
||||||
|
};
|
||||||
};
|
};
|
||||||
devShells.default = pkgs.mkShell {
|
devShells.default = pkgs.mkShell {
|
||||||
buildInputs = with pkgs; [deno typst];
|
buildInputs = with pkgs; [deno typst];
|
||||||
|
|||||||
Reference in new issue
Block a user