Using environment variables in .yml dependencies?

I would like to know if it is possible to use any other properties besides the one connected in the dependencies.yml configuration file.

For example, if I have a DEV_HOME environment variable, I would like to declare the repository location as follows:

repositories: - local dev: type: local artifact: ${env.DEV_HOME}/repository/[module] contains: mycompany -> * 

That way, I would avoid the pain of installing and maintaining a Nexus proxy and just exchange repositories through an environment variable.

thanks

+4
source share
2 answers

I can't get the environment variable to work, but maybe I did something wrong and quite possible (can someone check?).

A possible solution to your problem is to use this to declare your repository:

 repositories: - localModules: type: local artifact: "${application.path}/mods/[organisation]/[module]-[revision]/" contains: - custom 

This will use the folders in the root folder of your project as a place for your modules.

+2
source

Juste, to share the trick I used (on MacOS, it should also work on Linux) is to create a symbolic link to this specific path. Each other member of the team creates the same symbolic link to their own path and location, so that everyone can place their own local repository wherever they want.

I will try to check if I can offer some improvement for the recognizer when I have a chance.

Greetings

+1
source

Source: https://habr.com/ru/post/1385765/


All Articles