This repository contains a Python template designed to be used within the Python Script node in Dynamo for Revit workflows.
It includes a collection of libraries frequently utilized in my developments, alongside various methods and classes I sporadically employ.
The intention is to provide a foundational script that can be adapted and expanded upon for diverse and complex Revit automation tasks.
-
Download the latest release (clicking here) and find the
PythonTemplate.py
file. -
Locate DynamoSettings.xml File: Navigate to
%appdata%\Dynamo\Dynamo Revit\
and open the desired version. -
Edit Template Path: Add or modify the
<PythonTemplateFilePath>
line in theDynamoSettings.xml
file to:<PythonTemplateFilePath> <string>C:\Users\{CURRENTUSER}\AppData\Roaming\Dynamo\Dynamo Revit\{VERSION}\PythonTemplate.py</string> </PythonTemplateFilePath>
Replace
{CURRENTUSER}
with your windows username and{VERSION}
with your dynamo current version.
- Add Template File: Copy and paste the
PythonTemplate.py
file in the same location specified in the step #3.
- Documentation: Comment your code generously. Explain what each major block or function does, especially if the logic is complex.
- Error Handling: Always include error handling to manage and anticipate failures gracefully.
- Version Control: Keep track of changes and versions of your scripts, especially as they grow in complexity and number.
Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE
for more information.
Maycon Freitas
Project Link: https://github.com/mayconrfreitas/dynamo-revit-python-template