Locking Libraries

When working with libraries shared across multiple component projects, it's crucial to protect your logic. One way to do this is by locking the library to prevent unintended modifications and ensure consistency across projects.

As a best practice, all iNTERFACEWARE components have locked libraries. When building your own libraries, we recommend you follow this practice too.

When a library is locked:

  1. It is set to “read-only” mode so it’s visually clear and prevents the library from being edited.

  2. Users can modify other project files and safely push changes to the component repository without updating the library.

  3. The gitmodules link becomes https:// based instead of git@ based, enabling customers who don’t use Bitbucket to pull updates for our iNTERFACEWARE libraries.

Locking and Unlocking Libraries:

To lock or unlock a library, use the file menu,in the project tree. If you want to edit and push changes to a library repository, it must first be unlocked.

If you need to customize and create your own version of an iNTERFACEWARE library, it can be unlocked. Unlocking on of our libraries will mean that you must fork off from the iNTERFACEWARE library repository to your own and will no longer get updates.

When you unlock an iNTERFACEWARE library, a warning screen will notify you that you do not have write access to the library repository. This means you will be unable to push any changes to the library repository and update the shared library.

If you wish to continue to unlock the library, you’ll need to then select Configure Repository to point the library to a repository within your git server, which you have write access to. 

 

 

 

Related pages