Skip to content

Conversation

@mrodm
Copy link
Contributor

@mrodm mrodm commented Feb 21, 2023

Fixes #1154

This PR adds the following folders to be considered skipped when building the package:

  • .git
  • build

This is needed when the package files are directly located in the root of the repository.

As it is now, elastic-package build command copies all the folders/files except _dev. As the build folder is created in the root of the repository (same as other package files) it is also copied to the build folder again. .git folder would be also copied along with the others.

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2023-02-21T15:20:38.336+0000

  • Duration: 2 min 6 sec

🤖 GitHub comments

Expand to view the GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

Copy link
Member

@jsoriano jsoriano left a comment

Choose a reason for hiding this comment

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

👍

@mrodm mrodm marked this pull request as ready for review February 21, 2023 17:28
@mrodm mrodm self-assigned this Feb 21, 2023
Copy link
Contributor

@ruflin ruflin left a comment

Choose a reason for hiding this comment

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

LGTM. Did run on this branch and now everything works as expected. As side effect seems also to be that now the build command is faster which can be explained if less files have to be copoied.

One general issue that seems to persist is that it copies all files in my .gitignore files and even adds them to the package. For example my .idea files are in there which I didn't intend to share :-)

Lets get this in but I think it is a topic that needs further discussion as packages will accidentally contain files which users did not expect to be in there.

@mrodm
Copy link
Contributor Author

mrodm commented Feb 22, 2023

One general issue that seems to persist is that it copies all files in my .gitignore files and even adds them to the package. For example my .idea files are in there which I didn't intend to share :-)

I've created a new issue for this #1156, feel free to update the description if needed @ruflin .

@mrodm mrodm merged commit 47a2456 into elastic:main Feb 22, 2023
@mrodm mrodm deleted the add_skipped_dirs branch February 22, 2023 09:14
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.

Error when building a package in a separated repository

4 participants