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

Support Partial Replacements in File #158

Open
richbenmintz opened this issue Mar 14, 2025 · 2 comments
Open

Support Partial Replacements in File #158

richbenmintz opened this issue Mar 14, 2025 · 2 comments
Labels
question Further information is requested

Comments

@richbenmintz
Copy link

richbenmintz commented Mar 14, 2025

What is the question?

Is there functionality to modify the default_lakehouse found in the #METADATA section of the notebook definition?

# METADATA ********************

# META {
# META   "kernel_info": {
# META     "name": "synapse_pyspark"
# META   },
# META   "dependencies": {
# META     "lakehouse": {
# META       "default_lakehouse": "8da5e04c-2ecc-47e3-ab45-9dc7e8adb69b",
# META       "default_lakehouse_name": "lh_config",
# META       "default_lakehouse_workspace_id": "7157d32b-5d50-4125-bb55-8c60f27cccbd"
# META     }
# META   }
# META }

### Additional context

No response

@richbenmintz richbenmintz added the question Further information is requested label Mar 14, 2025
@shirasassoon
Copy link
Contributor

@richbenmintz Thank you for your question, the answer is yes! Please check out parameterization. You can leverage parameterization to find and replace specified strings found in the repository files, such as the default_lakehouse connection string, default_lakehouse_name, etc. Please take a look at our documentation on parameterization for additional guidance and a relevant example: https://microsoft.github.io/fabric-cicd/latest/how_to/parameterization/

Also, we are in the process of refactoring our parameter file structure so please keep an eye out for updated documentation in the near future.

@richbenmintz
Copy link
Author

Hi @shirasassoon,

Thanks, I understand that find and replace will replace all instances of a string with the defined replacement value, however I may not want to replace all instances of 'lh_config' with some other value in my file. It would be great to have the ability to define in which files and or types of files that I want to perform the replace functionality. Not sure if a file name includes or a file name excludes makes for sense. but something like:
- fileType: notebooks
- include: all

@JacobKnightley JacobKnightley changed the title Question Support Partial Replacements in File Mar 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants