unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* guix graph build phases
@ 2022-11-22 21:32 jgart
  2022-11-22 21:34 ` jgart
  2022-11-22 22:12 ` Julien Lepiller
  0 siblings, 2 replies; 9+ messages in thread
From: jgart @ 2022-11-22 21:32 UTC (permalink / raw)
  To: Guix Devel

hi,

`guix graph --phases` shows the order of phases for a particular package
and any custom phases that were introduced, deleted, replaced, etc. with
graphviz

wdyt



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: guix graph build phases
  2022-11-22 21:32 guix graph build phases jgart
@ 2022-11-22 21:34 ` jgart
  2022-11-22 22:12 ` Julien Lepiller
  1 sibling, 0 replies; 9+ messages in thread
From: jgart @ 2022-11-22 21:34 UTC (permalink / raw)
  To: Guix Devel

On Tue, 22 Nov 2022 15:32:54 -0600 jgart <jgart@dismail.de> wrote:
> wdyt

or maybe it should be:

guix build gnome-recipes --graph-phases


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: guix graph build phases
  2022-11-22 21:32 guix graph build phases jgart
  2022-11-22 21:34 ` jgart
@ 2022-11-22 22:12 ` Julien Lepiller
  2022-11-22 22:43   ` jgart
  2022-12-05 16:10   ` jgart
  1 sibling, 2 replies; 9+ messages in thread
From: Julien Lepiller @ 2022-11-22 22:12 UTC (permalink / raw)
  To: jgart, Guix Devel

[-- Attachment #1: Type: text/plain, Size: 406 bytes --]

The graph will always be flat, since it's a list, so graphviz would be a bit overkill :). Being able to list phases could still be cool :)

Le 22 novembre 2022 22:32:54 GMT+01:00, jgart <jgart@dismail.de> a écrit :
>hi,
>
>`guix graph --phases` shows the order of phases for a particular package
>and any custom phases that were introduced, deleted, replaced, etc. with
>graphviz
>
>wdyt
>
>

[-- Attachment #2: Type: text/html, Size: 674 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: guix graph build phases
  2022-11-22 22:12 ` Julien Lepiller
@ 2022-11-22 22:43   ` jgart
  2022-11-23  6:12     ` Julien Lepiller
  2022-12-05 16:10   ` jgart
  1 sibling, 1 reply; 9+ messages in thread
From: jgart @ 2022-11-22 22:43 UTC (permalink / raw)
  To: Julien Lepiller; +Cc: Guix Devel

On Tue, 22 Nov 2022 23:12:16 +0100 Julien Lepiller <julien@lepiller.eu> wrote:
> The graph will always be flat, since it's a list, so graphviz would be a bit overkill :). Being able to list phases could still be cool :)

How about with the plantuml that have packaged?


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: guix graph build phases
  2022-11-22 22:43   ` jgart
@ 2022-11-23  6:12     ` Julien Lepiller
  2022-11-23  7:09       ` jgart
  0 siblings, 1 reply; 9+ messages in thread
From: Julien Lepiller @ 2022-11-23  6:12 UTC (permalink / raw)
  To: jgart; +Cc: Guix Devel

[-- Attachment #1: Type: text/plain, Size: 449 bytes --]

I don't get why you want a picture. Could you share an example of what it would look like?

Le 22 novembre 2022 23:43:19 GMT+01:00, jgart <jgart@dismail.de> a écrit :
>On Tue, 22 Nov 2022 23:12:16 +0100 Julien Lepiller <julien@lepiller.eu> wrote:
>> The graph will always be flat, since it's a list, so graphviz would be a bit overkill :). Being able to list phases could still be cool :)
>
>How about with the plantuml that have packaged?

[-- Attachment #2: Type: text/html, Size: 847 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: guix graph build phases
  2022-11-23  6:12     ` Julien Lepiller
@ 2022-11-23  7:09       ` jgart
  2022-11-23  7:11         ` jgart
  2022-11-23  7:29         ` jgart
  0 siblings, 2 replies; 9+ messages in thread
From: jgart @ 2022-11-23  7:09 UTC (permalink / raw)
  To: Julien Lepiller; +Cc: Guix Devel

On Wed, 23 Nov 2022 07:12:55 +0100 Julien Lepiller <julien@lepiller.eu> wrote:
> I don't get why you want a picture. Could you share an example of what it would look like?

I was just thinking of something like a flowchart for the build phases.

For example, python-build-system's phases as a flowchart in mermaidjs:

%% python-build-system phases
flowchart TB
    unpack --> 
    ensure-no-mtimes-pre-1980 -->
    enable-bytecode-determinism --> 
    ensure-no-cythonized-files --> 
    build --> 
    install -->
    add-install-to-pythonpath --> 
    add-install-to-path -->
    wrap --> 
    check -->
    sanity-check --> 
    rename-pth-file -->
    strip

Here's the rendered mermaid flowchart:

https://kroki.io/mermaid/svg/eNptjz0OwjAMhfeeIgujJdhgYeAMXMBNjGKRP8WuqnJ6SloRCeHt2Z_t9w4HUxb1OcE4cXAgiyhFUzwKyfAIebYeq5r7bTBrTamgfRqAq2makkyVIGWIypEEyqpOl_Pxg-wEjoFgXJRsdgSOlGrkxBL_nbHNDL_IwYMDSWeavy45iWII3z_oHOw90AxbqILq-8ovsg_bbK5YOmk9bSmbEkysC3ybG1PXZJGgqG9OO62VyxteU2aW

The above diagram can easily be rewritten in plantuml and plantuml supports ascii diagrams also but ymmv:

https://www.planttext.com/api/plantuml/svg/RL0x2iCm3DrrYbn0q6vj0YK7wUBOAX6nPMChbFJqTPmiXMxl8_6UD1OrMTVW0PJLKvSsdQFWjB9tMBQY5Bgd0BGvW7wLPEmoG4zIrame4ODoe8AfiklzTccUcJpXj2dPw0WTAUN0mYNyRDeMnXzo-69FfPejk4DyLCnIKxq_cN4EJmKrub4q6Pt_U8VwpYQTotOckvou667Ti4cLvjes42QTMubzG3EdORyv9e2HnDK7VG40

@startuml
title python-build-system \n
start
:unpack;
:ensure-no-mtimes-pre-1980;
:enable-bytecode-determinism;
:ensure-no-cythonized-files;
:build -->;
:install -->;
:add-install-to-pythonpath;
:add-install-to-path;
:wrap -->;
:check -->;
:sanity-check;
:rename-pth-file;
:strip;
stop
@enduml

Where you thinking of capturing different information about the phases?


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: guix graph build phases
  2022-11-23  7:09       ` jgart
@ 2022-11-23  7:11         ` jgart
  2022-11-23  7:29         ` jgart
  1 sibling, 0 replies; 9+ messages in thread
From: jgart @ 2022-11-23  7:11 UTC (permalink / raw)
  To: Julien Lepiller; +Cc: Guix Devel

On Wed, 23 Nov 2022 01:09:43 -0600 jgart <jgart@dismail.de> wrote:

oops ignore the typos here:

> :build -->;
> :install -->;
> :add-install-to-pythonpath;
> :add-install-to-path;
> :wrap -->;
> :check -->;


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: guix graph build phases
  2022-11-23  7:09       ` jgart
  2022-11-23  7:11         ` jgart
@ 2022-11-23  7:29         ` jgart
  1 sibling, 0 replies; 9+ messages in thread
From: jgart @ 2022-11-23  7:29 UTC (permalink / raw)
  To: Julien Lepiller; +Cc: Guix Devel

On Wed, 23 Nov 2022 01:09:43 -0600 jgart <jgart@dismail.de> wrote:
> On Wed, 23 Nov 2022 07:12:55 +0100 Julien Lepiller <julien@lepiller.eu> wrote:

> %% python-build-system phases
> flowchart TB
>     unpack --> 
>     ensure-no-mtimes-pre-1980 -->
>     enable-bytecode-determinism --> 
>     ensure-no-cythonized-files --> 
>     build --> 
>     install -->
>     add-install-to-pythonpath --> 
>     add-install-to-path -->
>     wrap --> 
>     check -->
>     sanity-check --> 
>     rename-pth-file -->
>     strip
> 

The above is the unmodified python-build-system phases but our idea here
is to generate them for each package and to account for changes made by
the modify-phases macro?


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: guix graph build phases
  2022-11-22 22:12 ` Julien Lepiller
  2022-11-22 22:43   ` jgart
@ 2022-12-05 16:10   ` jgart
  1 sibling, 0 replies; 9+ messages in thread
From: jgart @ 2022-12-05 16:10 UTC (permalink / raw)
  To: Julien Lepiller; +Cc: Guix Devel

On Tue, 22 Nov 2022 23:12:16 +0100 Julien Lepiller <julien@lepiller.eu> wrote:
> The graph will always be flat, since it's a list, so graphviz would be a bit overkill :). Being able to list phases could still be cool :)

Thinking more about this now I realize that just having a way to list the phases would be great and probably not difficult to implement.

On another note,

What do you think if it would be possible to add documentation to custom phases?

I realize that the name of the phases acts as a short documentation but
what if we could write a short description documenting why the phase
is needed?

Then, when we list the phases we could also list the documentation for that phase.

overkill? bloat?

all best,

jgart


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-12-05 16:11 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-22 21:32 guix graph build phases jgart
2022-11-22 21:34 ` jgart
2022-11-22 22:12 ` Julien Lepiller
2022-11-22 22:43   ` jgart
2022-11-23  6:12     ` Julien Lepiller
2022-11-23  7:09       ` jgart
2022-11-23  7:11         ` jgart
2022-11-23  7:29         ` jgart
2022-12-05 16:10   ` jgart

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

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).