Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

go-cleanarch: override infrastructure layer name #47

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mrsndmn
Copy link

@mrsndmn mrsndmn commented Dec 17, 2021

Due to go-cleanarch readme default infrastructure layer package name is infrastructure or infra.

In this project infrastructure layer package named ports.

I filtered modules and layers from debug go-cleanarch output. There was no infrastructure layer

$ go-cleanarch -debug  ./ 2>&1 | grep -v 'Layer:}' | grep 'metadata: {Module' | cut -d' ' -f 6-7 | sort | uniq              
{Module:trainer Layer:application}
{Module:trainer Layer:domain}
{Module:trainer Layer:interfaces}
{Module:trainings Layer:application}
{Module:trainings Layer:domain}
{Module:trainings Layer:interfaces}

With overrided -infrastructure flag infrastructure layer appears in output

$ go-cleanarch -debug -infrastructure ports ./ 2>&1 | grep -v 'Layer:}' | grep 'metadata: {Module' | cut -d' ' -f 6-7 | sort | uniq
{Module:trainer Layer:application}
{Module:trainer Layer:domain}
{Module:trainer Layer:infrastructure}
{Module:trainer Layer:interfaces}
{Module:trainings Layer:application}
{Module:trainings Layer:domain}
{Module:trainings Layer:infrastructure}
{Module:trainings Layer:interfaces}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant