Skip to content

Conversation

@sherif181
Copy link

@sherif181 sherif181 commented Nov 1, 2025

@Skyaero42 Skyaero42 added the Build Anything related to building, compiling label Nov 1, 2025
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe call this dockerbuild.sh? Because "build" is very broad but this is docker specific.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we write this folder name without a minus? We have no other folder in this style.

@xezon xezon requested a review from OmniBlade November 2, 2025 09:42
Copy link

@OmniBlade OmniBlade left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should the build script not live under scripts and the dockerbuild folder not live under resources rather than both ending up in the top level?

*.user
*.ncb
/build*
!/build.sh

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change to .gitignore is no longer required.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the docker files should not be too far from the build script but I will split it

But moving it like this causes a problem with the working dir

I can either :

  1. implement it to be run from root ie:
    scripts/dockerbuild.sh
  2. or from inside the script folder

having both will need some folder search magic
This will end up to be confusing

having it at least the build script in root makes easier to implement more usable and consistent -> there are 5 build related files and folders in the root (build,cmake....)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The script shouldn't care what path its run from, it should detect its path and work out where other stuff is relative to itself. Relying on the current working dir is normally a bad idea and will just generate support requests when people run it wrong.

You already make use of basename to get the script name, using dirname will get you the containing folder (lets say scripts) and running direname on that folder would get you the top level project folder. You can then use that to construct the other paths you need.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Build Anything related to building, compiling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants