Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Conversation

@godofredoc
Copy link
Contributor

Recipes v2 do not know the final paths in advance to be provided in the
configurations. The support of relative paths allow to calculate full
paths at runtime.

This change is also moving the creation of zips to the script to
simplify the recipes.

Bug: flutter/flutter#81855

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the Flutter Style Guide and the C++, Objective-C, Java style guides.
  • I listed at least one issue that this PR fixes in the description above.
  • I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt. See testing the engine for instructions on
    writing and running engine tests.
  • I updated/added relevant documentation (doc comments with ///).
  • I signed the CLA.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Recipes v2 do not know the final paths in advance to be provided in the
configurations. The support of relative paths allow to calculate full
paths at runtime.

This change is also moving the creation of zips to the script to
simplify the recipes.

Bug: flutter/flutter#81855
@godofredoc godofredoc requested review from jmagman and zanderso August 5, 2022 20:57
Copy link
Member

@zanderso zanderso left a comment

Choose a reason for hiding this comment

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

AFAIK, this script is only invoked from the recipe, and so I'm not sure there's any reason that it needs to be a shell script. Would it be too much trouble to replace it with a python script?

@godofredoc
Copy link
Contributor Author

AFAIK, this script is only invoked from the recipe, and so I'm not sure there's any reason that it needs to be a shell script. Would it be too much trouble to replace it with a python script?

It can definitely be translated to python but it will require a few iterations to deprecate the bash script. I can create a bug and translate it as a follow up.

AFAIK, this script is only invoked from the recipe, and so I'm not sure there's any reason that it needs to be a shell script. Would it be too much trouble to replace it with a python script?

It is possible to translate it to python but it may take a few iterations to implement it and test it. I created flutter/flutter#109068 to follow up on the migration to python.


# Create the final zip file.
pushd $OUTPUT_DIR
zip -r "$ZIP_DESTINATION/ios-objcdoc.zip" .
Copy link
Member

Choose a reason for hiding this comment

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

Will the current recipe fail if a file already exists at this path?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No, ios-objcdoc is generated in a temp file before uploading. If the file exists the zip command overrides it.

Copy link
Member

@jmagman jmagman left a comment

Choose a reason for hiding this comment

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

I may not have the bash-foo to say, but LGTM? Should wait for @zanderso or his delegate though.

pushd "$SCRIPT_DIR/../../flutter"

FLUTTER_UMBRELLA_HEADER=$(find ../out -maxdepth 4 -type f -name Flutter.h | grep 'ios_' | head -n 1)
echo "$(pwd)"
Copy link
Member

Choose a reason for hiding this comment

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

Is this a leftover debug print?

if [ "${OUTPUT_DIR:0:1}" != "/" ]
then
ZIP_DESTINATION="$SCRIPT_DIR/../../$1"
OUTPUT_DIR="$ZIP_DESTINATION/objectc_docs"
Copy link
Member

Choose a reason for hiding this comment

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

Should OUTPUT_DIR also be nested under ZIP_DESTINATION when $1 is an absolute path?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done!

@godofredoc godofredoc added the autosubmit Merge PR when tree becomes green via auto submit App label Aug 9, 2022
@auto-submit auto-submit bot merged commit 9aaa21a into flutter:main Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
zanderso added a commit that referenced this pull request Aug 9, 2022
godofredoc pushed a commit that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 9, 2022
godofredoc added a commit that referenced this pull request Aug 10, 2022
emilyabest pushed a commit to emilyabest/engine that referenced this pull request Aug 12, 2022
emilyabest pushed a commit to emilyabest/engine that referenced this pull request Aug 12, 2022
@godofredoc godofredoc deleted the update_objectc_script branch January 12, 2024 19:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

autosubmit Merge PR when tree becomes green via auto submit App

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants