Skip to content

An environment manager to setup playkit-js-* projects across repos

License

Notifications You must be signed in to change notification settings

kaltura/playkit-js-env-manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

68 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PlayKit JS Env Manager - An environment manager to setup playkit-js-* projects across repos

PlayKit JS Env Manager is a command line tool which aims to solve the development challenges for multiple packages (playkit-js-*) that integrates to a single application (Kaltura Player in our case).

Prerequisites

1. Install ttab

First, install ttab globally on your machine:

$ [sudo] npm install ttab -g

Then, go to System Preferences > Security & Privacy, tab Privacy, select Accessibility, unlock, and make sure Terminal.app is in the list on the right and has a checkmark.

2. Clone kaltura-player-js repository

$ git clone https://github.com/kaltura/kaltura-player-js.git
$ cd kaltura-player-js
$ yarn

3. Folder structure

Pay attention that all playkit-js-* repos including kaltura-player-js repo must be under the same parent directory. An example for a valid folder structure is:

- repos
  - playkit-js
  - playkit-js-hls
  - playkit-js-dash
  - playkit-js-ima
  - playkit-js-ui
  - playkit-js-youbora
  - playkit-js-providers
  - playkit-js-kanalytics
  - kaltura-player-js

Quick Start

  • Go to package.json file in kaltura-player-js project.
  • Observe under scripts the following commands:
"scripts": {
  ....
  "playkit-dev:start": "playkit-dev start",
  "playkit-dev:stop": "playkit-dev stop",
  "playkit-rel": "playkit-rel start"
  ...
}

     Those commands will helps us to run the required modes.

  • Observe new entry named envManager which contains the following configuration:
  "envManager": {
    "devMode": {},
    "releaseMode": []
  }
  • To run a certain script, simply open your terminal, go to kaltura-player-js project:
$ cd PATH/TO/kaltura-player-js

     and run one of:

yarn run playkit-rel
yarn run playkit-dev:start
yarn run playkit-dev:stop

Aliases for playkit repos

Each repo has an alias to shorten its name and thus manipulate the configuration more easily and quickly:

  • playkit-js -> core
  • playkit-js-ui -> ui
  • playkit-js-ima -> ima
  • playkit-js-hls -> hls
  • playkit-js-dash -> dash
  • playkit-js-providers -> providers
  • playkit-js-youbora -> youbora
  • playkit-js-kanalytics -> kanalytics
  • playkit-js-ott-analytics -> ott-analytics
  • playkit-js-google-analytics -> google-analytics
  • playkit-js-comscore -> comscore
  • playkit-js-kava -> kava
  • playkit-js-vr -> vr

Configuration

devMode

Commands

  • playkit-dev:start
  • playkit-dev:stop

Structure

  "devMode": {
    "alias": "version",
    ...
  }
Property Type Possible Values Description
version string 'latest','local','vX.X.X' Specifies the package version that the corresponding repo will checkout to on the local machine. For 'latest' it will checkout to the master branch. For 'local' it will stay on the current local branch (whatever that is).

Example:

  "devMode": {
    "core": "v0.10.0",
    "ui": "latest",
    "hls": "local"
  }

releaseMode

Commands

  • playkit-rel

Structure

  "releaseMode": [
    "alias1",
    "alias2",
    "alias3",
    ...
  ]

Example:

  "releaseMode": [
    "core",
    "youbora",
    "hls",
    ...
  ]

Compatibility

This tool has been tested only on Mac OS.

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

License

This project is licensed under the AGPL-3.0 License - see the LICENSE.md file for details

About

An environment manager to setup playkit-js-* projects across repos

Resources

License

Stars

Watchers

Forks

Packages

No packages published