Skip to content

Commit

Permalink
Add link to install script to 'dist' folder
Browse files Browse the repository at this point in the history
  • Loading branch information
dotherightthing committed Dec 15, 2024
1 parent 44716a9 commit 0422eb9
Show file tree
Hide file tree
Showing 7 changed files with 208 additions and 62 deletions.
30 changes: 27 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,27 @@
* [e0ce59b] Update documentation
* [16fccfb] Reorganise documentation
* [1d97106] Resave set
* [6d7071f] Add link to install script to 'dist' folder
* [44716a9] Stream Deck - Replace keyboard icon with download from Font Awesome
* [11facd1] Stream Deck - Change Select and Save icons in Remix Deck; remove Trigger button
* [ba166fb] Stream Deck - Add button to generate screenshots of Stream Deck pages
* [cb91c83] Stream Deck - Add Reverse button; Change Pause button to Stop
* [fe4683b] Refine folder structure, install presets into appropriate live folders, move legacy presets to control-live repository (fixes #54, fixes #55)
* [1b013b1] Update Streamdeck mappings in CSV format
* [d8b10e6] Remove redundant files
* [d9fac38] Remove redundant files
* [b904330] Update Streamdeck mappings in CSV format
* [5757a0b] Fix build error (#50), refine folder structure
* [0f9caf4] Document version changes; add Streamdeck mappings in CSV format; remove redundant button icons; rename profile pages
* [2a582df] Document version changes; add Streamdeck mappings in CSV format; remove redundant button icons; rename profile pages
* [2fe19fa] Remove redundant SHIFTed reset from Dry/Wet button
* [b26c377] Document version changes; add Streamdeck mappings in CSV format; fix missing M4L preset
* [54ebdb8] Update library version, update Node and NPM versions, update dependencies
* [589d7f8] Rename Streamdeck profile and name pages
* [7577cab] Remove Streamdeck backup files as they contain unrelated profiles
* [a21e2d0] Copy streamdeck-midi-plugin/cycle-files into Application Support folder (fixes #52) (+1 squashed commit) Squashed commits: [203aedd] Copy streamdeck-midi-plugin/cycle-files into Application Support folder (fixes #52)
* [4602d40] Version 6 (#49)
* [50801bb] Add app openers / profile switchers for Traktor and Live
* [9d7f3d4] MCU - update app targets from Ableton Live 11 to Ableton Live 12; remove links to launch Traktor and Ableton as these are superseded by StreamDeck profiles
* [b240d20] Add Button Creator icon
* [0c94794] Add link to Supreme MOD Patreon page
* [d657f82] BPM/2 and BPMx2 now also disable BPM Lock (Grid Analysis Lock)
* [0d88117] Sidecar script not working with macOS Sonoma, so change to brightness toggle
* [5169836] Fix Push2 port
104 changes: 104 additions & 0 deletions INSTALL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
# Control Traktor

## System requirements

* macOS (tested on *Sonoma 14.7.1*)
* Traktor Pro (tested on *Traktor 3.11*)
* Terminal (to run installation script)

### For S8 controls

* Traktor Kontrol S8

### For routing S8 inputs to Deck D

* Rogue Amoeba Loopback (tested on *2.4.5*)

### For Stream Deck controls

* Elgato Stream Deck XL

### For pitching of deck key

* Korg nanoKEY2

### For MIDI sequencing of hot cues & freeze slices

* Ableton Live (tested on *Live 12*)
* Push 2
* ClyphX Pro (for *Live 12*)

---

## Installation script

1. Download the latest release zip from <https://github.com/dotherightthing/control-traktor/releases>
2. Extract the zip folder
3. Open Terminal.app
4. Type `cd `, drag the extracted zip folder into Terminal, then press ENTER, to set the release folder as the root directory
5. Type `chmod a+x install.sh` followed by ENTER, to make the installation script executable
6. Type `./install.sh 3.11.1` followed by ENTER, to run the installation script (note: this library has only been tested with Traktor `3.11.1`)
7. Open *live/CT6.als* to view the Live set

The following files will automatically be installed:

* `Macintosh HD/Users/USERNAME/nativeKONTROL`
* `ClyphX_Pro`
* `Macintosh HD/Users/USERNAME/Documents/Native Instruments`
* `CT6 - App Export.tsi`
* `CT6 - Deck A.tsi`
* `CT6 - Deck B.tsi`
* `CT6 - Global.tsi`
* `CT6 - Korg nanoKEY2.tsi`
* `CT6 - S8.tsi`
* `CT6 - Streamdeck XL.tsi`
* `Macintosh HD/Users/USERNAME/Library/Application Support/Loopback`
* `Devices.plist`
* `RecentApps.plist`
* `Macintosh HD/Users/USERNAME/Library/Application Support/control-traktor`
* `live`
* `CT6.als`
* `streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files`
* various XML files
* `Macintosh HD/Users/USERNAME/Music/Ableton/User Library/Presets`
* `Instruments/Drum Rack`
* `CT6 SeqPads.adg`
* `Instruments/Instrument Rack`
* `CT6 Rack.adg`
* `MIDI Effects/Max MIDI Effect`
* `CT6 Params.adv`
* `CT6 Params.amxd`
* `MIDI Effects/Pitch`
* `CT6 Liveto Traktor.adv`

## Manually install the copied controller mappings

1. Traktor > Settings > Add > Import TSI > Import Other... > `CT6 - App Export.tsi`
2. Traktor > Settings > Add > Import TSI > Import Other... > `CT6 - Deck A.tsi`
3. Traktor > Settings > Add > Import TSI > Import Other... > `CT6 - Deck B.tsi`
4. Traktor > Settings > Add > Import TSI > Import Other... > `CT6 - Global.tsi`
5. Traktor > Settings > Add > Import TSI > Import Other... > `CT6 - Korg nanoKEY2.tsi`
6. Traktor > Settings > Add > Import TSI > Import Other... > `CT6 - S8.tsi`
7. Traktor > Settings > Add > Import TSI > Import Other... > `CT6 - Streamdeck XL.tsi`

## Ableton Live

### Set up Virtual MIDI ports

These allow the Stream Deck XL and Ableton Live to communicate.

1. Open Audio MIDI Setup
2. Double-click IAC Driver (in red)
3. Click `+` to add a Bus
4. Double-click the bus name and rename to `StreamDeck2Daw`
5. Click `+` to add a second Bus
6. Double-click the second bus name and rename to `Daw2StreamDeck`
7. Ensure that *Device is online* is checked
8. Click *Apply*

### Enable Virtual MIDI ports

1. Open Ableton Live
2. Open *Settings* > *Link, Tempo & MIDI*
3. Under *Input Ports*, locate *IAC Driver (StreamDeck2Daw)* and select the *Track* and *Remote* checkboxes
4. Under *Input Ports*, locate *IAC Driver (Daw2StreamDeck)* and select the *Track* and *Remote* checkboxes
9 changes: 3 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,16 @@ A collection of settings and Max4Live devices for improved control over Traktor

## Installation only

1. Download `release.zip` from the latest [Release](https://github.com/dotherightthing/control-traktor/releases)
2. Unzip/expand the folder and copy to `~/Music/Ableton/User\ Library/` (note: devices may be a mix of Audio/Instrument/MIDI types)
3. See device usage instructions below (*Rename Selected Track*, *Presample Selected Track*)
1. See [INSTALL](https://github.com/dotherightthing/control-traktor/blob/main/INSTALL.md)

## Installation and development

This repo uses a build script so that I can write JavaScript in ES6 rather than ES5.

1. [Install Node and NPM](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) and [Git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git)
2. `git clone` this repo to `~/Music/Ableton/User Library/` (I also symlink this to my *Websites* folder so I can find it)
2. `git clone` this repo
3. Run `npm install` to install dependencies, run the build
4. Run `npm run watch` to lint and build as you save file changes
* Edit `src/js/m4l-*.js` - the Max-friendly (ES5) version of this file is updated in the `dist` folder
* Edit `dist/*.amxd` in Max - this file is copied back to the `src/live` folder
5. Run `npm run reinstall` to recreate `dist` folder

## Release
Expand All @@ -39,6 +35,7 @@ This repo uses a build script so that I can write JavaScript in ES6 rather than
* `build` script now copies Streamdeck XML files into *Library/Application Support/control-traktor/*
* Traktor screen
* Replaced custom hacks with [Supreme Edition Mod](https://www.patreon.com/c/supremeedition/posts)
* Refine installation

### Screenshots

Expand Down
14 changes: 8 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,12 @@
},
"scripts": {
"backup": "./scripts/backup.sh",
"build": "npm run backup && rm -rf dist && mkdir dist && ./scripts/dist.sh",
"build": "npm run backup && npm run dist",
"changelog": "git log --pretty='* [%h] %s' --no-merges $(git describe --tags --abbrev=0 @^)..@ > CHANGELOG.md",
"postinstall": "chmod a+x scripts/*sh && rm -rf dist && mkdir dist && npm run build",
"reinstall": "rm -r dist && rm -rf dist && mkdir dist && npm run build",
"release": "npm run build && npm run changelog && cp ./dist/* ./release",
"dist": "./scripts/dist.sh && cd ./dist && ./install.sh 3.11.1 && cd ../",
"postinstall": "chmod a+x scripts/*sh && npm run build",
"reinstall": "npm run build",
"release": "npm run build && npm run changelog && cp -r ./dist ./release",
"test": "echo \"Error: no test specified\" && exit 1",
"watch": "nodemon"
},
Expand All @@ -26,8 +27,9 @@
"url": "git+https://github.com/dotherightthing/control-traktor.git"
},
"keywords": [
"m4l",
"max4live"
"max4live",
"streamdeck",
"traktor-pro"
],
"author": "",
"license": "ISC",
Expand Down
4 changes: 1 addition & 3 deletions scripts/backup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# suppress both error message and exit code: 2>/dev/null || :
set -e

# if $GITHUB_ACTIONS does not exist 'then' script is being run locally
# if $GITHUB_ACTIONS does not exist 'then' script is being run locally rather than on CI
if [ -z "$GITHUB_ACTIONS" ]
then
cd "$INIT_CWD" \
Expand All @@ -29,6 +29,4 @@ then
&& echo "Backing up Loopback configuration files" \
&& cp ~/"Library/Application Support/Loopback/"*.plist "./src/loopback" \
&& echo "Backup tasks complete"
else
echo "CI, exiting"
fi
64 changes: 20 additions & 44 deletions scripts/dist.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

# File: ./scripts/dist.sh
# Description: Copy relevant files to the dist folder
# Description: Copy relevant files to dist folder for release
#
# Note:
# chmod a+x = Change access permissions of this file, to 'e[x]ecutable' for '[a]ll users'
Expand All @@ -15,46 +15,22 @@
# v: print shell input lines as they are read (including all comments!)
set -e



# if $GITHUB_ACTIONS does not exist 'then' script is being run locally
# TODO compile/copy to dist
# then copy to ~/Library/Application\ Support/control-traktor/live
# then copy to Live User Library etc if not CI
if [ -z "$GITHUB_ACTIONS" ]
then
cd "$INIT_CWD" \
&& echo "Installing configuration files for ClyphX Pro" \
&& cp "./src/clyphx-pro/"* ~/"nativeKONTROL/ClyphX_Pro" \
&& echo "Installing configuration files for Loopback" \
&& cp "./src/loopback/"*.plist ~/"Library/Application Support/Loopback" \
&& echo "Installing Ableton Live patches and presets" \
&& cp "./src/live/Instruments/Drum Rack/CT6 Seq Pads.adg" ~/"Music/Ableton/User Library/Presets/Instruments/Drum Rack" \
&& cp "./src/live/Instruments/Instrument Rack/CT6 Rack.adg" ~/"Music/Ableton/User Library/Presets/Instruments/Instrument Rack" \
&& cp "./src/live/MIDI Effects/Max MIDI Effect/CT6 Params.adv" ~/"Music/Ableton/User Library/Presets/MIDI Effects/Max MIDI Effect" \
&& cp "./src/live/MIDI Effects/Max MIDI Effect/CT6 Params.amxd" ~/"Music/Ableton/User Library/Presets/MIDI Effects/Max MIDI Effect" \
&& cp "./src/live/MIDI Effects/Pitch/CT6 Live to Traktor.adv" ~/"Music/Ableton/User Library/Presets/MIDI Effects/Pitch" \
&& echo "Copying files from ./src to ~/Library/Application Support/control-traktor/" \
&& rm -rf ~/"Library/Application Support/control-traktor/" || true \
&& mkdir -p ~/"Library/Application Support/control-traktor/live" \
&& cp "./src/live/"*.als ~/"Library/Application Support/control-traktor/live" \
&& mkdir -p ~/"Library/Application Support/control-traktor/streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files" \
&& cp "./src/streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files/"*.xml ~/"Library/Application Support/control-traktor/streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files" \
&& echo "Installing Ableton Live patches and presets" \
&& echo "Copying files from ./src to ./dist" \
&& cp -r "./src/live/"* "./dist" \
&& cp "./README.md" "./dist" \
&& cp "./src/streamdeck-xl/profiles/CT6.streamDeckProfile" "./dist" \
&& cp "./src/traktor/"*.png "./dist" \
&& cp "./src/traktor/"*.tsi "./dist" \
&& echo "Dist tasks complete"
else
cd "$INIT_CWD" \
&& echo "Copying files from ./src to ./dist" \
&& cp -r "./src/live/"* "./dist" \
&& cp "./README.md" "./dist" \
&& cp "./src/streamdeck-xl/profiles/CT6.streamDeckProfile" "./dist" \
&& cp "./src/traktor/"*.png "./dist" \
&& cp "./src/traktor/"*.tsi "./dist" \
&& echo "Dist tasks complete"
fi
cd "$INIT_CWD" \
&& echo "Recreating dist folder" \
&& rm -rf dist && mkdir dist \
&& echo "Copying files from ./src to ./dist" \
&& mkdir "dist/clyphx-pro" \
&& mkdir "dist/live" \
&& mkdir "dist/loopback" \
&& mkdir -p "dist/streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files" \
&& mkdir -p "dist/streamdeck-xl/profiles" \
&& mkdir "dist/traktor" \
&& cp "./scripts/install.sh"* "./dist" \
&& cp "./src/clyphx-pro/"* "./dist/clyphx-pro" \
&& cp -r "./src/live/"* "./dist/live" \
&& cp "./src/loopback/"*.plist "./dist/loopback" \
&& cp "./src/streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files/"* "./dist/streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files" \
&& cp "./src/streamdeck-xl/profiles/CT6.streamDeckProfile" "./dist/streamdeck-xl/profiles" \
&& cp "./src/traktor/"* "./dist/traktor" \
&& echo "Please read installation instructions at https://github.com/dotherightthing/control-traktor/blob/main/INSTALL.md." > ./dist/README.txt \
&& echo "Dist tasks complete"
45 changes: 45 additions & 0 deletions scripts/install.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
#!/bin/bash

# File: ./scripts/install.sh
# Description: Copy files from dist folder to system folders
#
# Note:
# chmod a+x = Change access permissions of this file, to 'e[x]ecutable' for '[a]ll users'
#
# Example:
# ---
# chmod a+x scripts/*.sh
# ---

# e: exit the script if any statement returns a non-true return value
# v: print shell input lines as they are read (including all comments!)
set -e

if [ -z "$1" ]; then
echo "Please call this script with 'install.sh 3.11.1', where 3.11.1 is the Traktor version"
fi

# if $GITHUB_ACTIONS does not exist 'then' script is being run locally rather than on CI
if [ -n "$1" ] && [ -z "$GITHUB_ACTIONS" ]
then
rm -rf ~/"Library/Application Support/control-traktor/" || true \
&& mkdir -p ~/"Library/Application Support/control-traktor/live" \
&& mkdir -p ~/"Library/Application Support/control-traktor/streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files" \
&& echo "Installing ClyphX Pro support files" \
&& cp "./clyphx-pro/"* ~/"nativeKONTROL/ClyphX_Pro" \
&& echo "Installing Loopback support files" \
&& cp "./loopback/"*.plist ~/"Library/Application Support/Loopback" \
&& echo "Installing Live support files" \
&& cp "./live/"*.als ~/"Library/Application Support/control-traktor/live" \
&& cp "./live/Instruments/Drum Rack/CT6 Seq Pads.adg" ~/"Music/Ableton/User Library/Presets/Instruments/Drum Rack" \
&& cp "./live/Instruments/Instrument Rack/CT6 Rack.adg" ~/"Music/Ableton/User Library/Presets/Instruments/Instrument Rack" \
&& cp "./live/MIDI Effects/Max MIDI Effect/CT6 Params.adv" ~/"Music/Ableton/User Library/Presets/MIDI Effects/Max MIDI Effect" \
&& cp "./live/MIDI Effects/Max MIDI Effect/CT6 Params.amxd" ~/"Music/Ableton/User Library/Presets/MIDI Effects/Max MIDI Effect" \
&& cp "./live/MIDI Effects/Pitch/CT6 Live to Traktor.adv" ~/"Music/Ableton/User Library/Presets/MIDI Effects/Pitch" \
&& echo "Installing Stream Deck support files" \
&& cp "./streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files/"*.xml ~/"Library/Application Support/control-traktor/streamdeck-xl/plugins/streamdeck-midi-plugin/cycle-files" \
&& echo "Installing Traktor support files" \
&& cp "./traktor/"* ~/"Documents/Native Instruments/Traktor $1" \
&& open "./traktor/" \
&& echo "Automatic install tasks complete."
fi

0 comments on commit 0422eb9

Please sign in to comment.