document how to extend makes #36

Closed
opened 2021-06-29 19:39:38 +02:00 by kamadorueda · 7 comments
kamadorueda commented 2021-06-29 19:39:38 +02:00 (Migrated from github.com)

there are some builtins people can invoke in makes.nix

for workflows not covered there people can create any combination of directories and files under the makes/ folder in their project. For each main.nix, at any location, an output is created and can be listed when running m. The main.nix format is a function that receives some arguments: github.com/fluidattacks/makes@c9b3746494/src/modules/outputs/default.nix (L8)

we should document all of this in a 'Extending makes' section

there are some builtins people can invoke in makes.nix for workflows not covered there people can create any combination of directories and files under the makes/ folder in their project. For each main.nix, at any location, an output is created and can be listed when running `m`. The main.nix format is a function that receives some arguments: https://github.com/fluidattacks/makes/blob/c9b374649459b216fcc51222c48957d2eaa58fee/src/modules/outputs/default.nix#L8 we should document all of this in a 'Extending makes' section
ludsrill commented 2021-07-13 22:13:29 +02:00 (Migrated from github.com)

I am working in a virtual machine, each time I run a test it takes up an amount of space on my hard disk until I run out of available space (25 Gb)

I've been using nix-collect-garbage but this command only cleans about 1 or 2Gb and at some point I lose all available space on my VM

Is there any method to clean all those temporary files from my hard disk?

I am working in a virtual machine, each time I run a test it takes up an amount of space on my hard disk until I run out of available space (25 Gb) I've been using `nix-collect-garbage` but this command only cleans about 1 or 2Gb and at some point I lose all available space on my VM Is there any method to clean all those temporary files from my hard disk?
kamadorueda commented 2021-07-13 22:47:27 +02:00 (Migrated from github.com)

I am working in a virtual machine, each time I run a test it takes up an amount of space on my hard disk until I run out of available space (25 Gb)

I've been using nix-collect-garbage but this command only cleans about 1 or 2Gb and at some point I lose all available space on my VM

Is there any method to clean all those temporary files from my hard disk?

Your repository HEAD is 479MB, you should optimize that if possible

Until we release a patch, you can do rm -rf /tmp/makes*

> I am working in a virtual machine, each time I run a test it takes up an amount of space on my hard disk until I run out of available space (25 Gb) > > I've been using `nix-collect-garbage` but this command only cleans about 1 or 2Gb and at some point I lose all available space on my VM > > Is there any method to clean all those temporary files from my hard disk? Your repository HEAD is 479MB, you should optimize that if possible Until we release a patch, you can do rm -rf /tmp/makes*
ludsrill commented 2021-07-13 23:00:21 +02:00 (Migrated from github.com)

perfect, thx for suggestions

perfect, thx for suggestions
kamadorueda commented 2021-07-13 23:12:04 +02:00 (Migrated from github.com)

perfect, thx for suggestions

update makes, it's fixed now

> perfect, thx for suggestions update makes, it's fixed now
ludsrill commented 2021-07-13 23:40:45 +02:00 (Migrated from github.com)

When using makeDerivation I must use touch "${out}" inside my builder.sh file if I don't do that I will get this

builder for '/nix/store/6ds08z4cmmql60cyg2yrbjvbk3467lg1-build_solutions_lobster.drv' failed to produce output path '/nix/store/wkmika79pg7bbwabs1ay9a3ydbpmsijq-build_solutions_lobster'

This generates a blank file that is kept when the test has finished,
Is this file necessary?
Is it possible to prevent the file from being kept in my directory using makes, or it is necessary to delete it using bash in my case?

When using makeDerivation I must use `touch "${out}"` inside my builder.sh file if I don't do that I will get this ``` builder for '/nix/store/6ds08z4cmmql60cyg2yrbjvbk3467lg1-build_solutions_lobster.drv' failed to produce output path '/nix/store/wkmika79pg7bbwabs1ay9a3ydbpmsijq-build_solutions_lobster' ``` This generates a blank file that is kept when the test has finished, Is this file necessary? Is it possible to prevent the file from being kept in my directory using makes, or it is necessary to delete it using bash in my case?
kamadorueda commented 2021-07-13 23:57:57 +02:00 (Migrated from github.com)

you can add the result* files to the gitignore

by design a derivation must produce an output, the smallest one is touch $out

it's a small price to pay for the benefits makeDerivation has

you can add the result* files to the gitignore by design a derivation must produce an output, the smallest one is `touch $out` it's a small price to pay for the benefits makeDerivation has
kamadorueda commented 2021-08-02 19:14:47 +02:00 (Migrated from github.com)

The module system has been documented,

Gonna document the arguments now

The module system has been documented, Gonna document the arguments now
This discussion has been locked. Commenting is limited to contributors.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
justin/makes#36
No description provided.