Init Company

Experimental

Create the directory structure and common files to get you started with Orchescala.

The Structure of the Process-Projects looks like this:

myProject1  myProject2  ...
      |         |         |
     company-orchescala
            |  
        orchescala

The idea is that you have a company layer, where you can override Company specific settings.

Be aware that one of the main advantages is the concept of Convention over Configuration.

At the moment not everything is configurable.

So try to stick to the conventions, whenever possible.

  1. Create a directory for your company development:

    mkdir ~/dev-mycompany

    Be aware that the company name (mycompany) must be lowercase to work properly.

  2. Create helperCompany.scala in your company directory and open it.

    cd ~/dev-mycompany
    touch helperCompany.scala
    open helperCompany.scala
  3. Copy the following content to helperCompany.scala:

    #!/usr/bin/env -S scala shebang
    // DO NOT ADJUST. This file is replaced by `./helper.scala update`.
    
    //> using dep io.github.pme123::orchescala-helper:0.2.9
    
    import orchescala.helper.dev.DevCompanyHelper
    
    @main
    def run(command: String, arguments: String*): Unit =
     DevCompanyHelper.run(command, arguments*)
  4. Make the file executable:

    chmod +x helperCompany.scala
  5. Create the company directory structure:

    ./helperCompany.scala init
  6. Set the environment variables for the company:

    export SWISSCOM_MVN_REPOSITORY_USERNAME=myUsername
    export SWISSCOM_MVN_REPOSITORY_PASSWORD=myPassword
    export SWISSCOM_MVN_RELEASE_REPOSITORY="https://myArtifactory.com/myReleaseRepo"
    export SWISSCOM_MVN_DEPENDENCY_REPOSITORY="https://myArtifactory.com/myDependencyRepo"
  7. Open the company-orchescala directory with your IDE (I use Intellij).

  8. Import the sbt project. The project should compile without errors.

  9. Go to the generated Classes and make adjustments as needed.

  10. Add your project to your Version Source Control.

  11. Release the company-orchescala project to your repository.

Next Step: Create Project