Skip to content

Instantly share code, notes, and snippets.

@timolaine
timolaine / Add consecutive ID to selection.ajs
Created November 5, 2025 12:56
Add consecutive ID to selection in #jArchi
/*
* Add consecutive ID to selection
* (c) 2025 Timo Laine www.timoroso.com
*/
console.log("Add consecutive ID to selection");
var propName = window.prompt("To which property do you want to add a consecutive ID for selected elements or relations? (leave empty to cancel)?", "");
if (propName) {
@timolaine
timolaine / Color relations by property value.ajs
Last active November 5, 2025 14:02
Colorize all relationships in a view based on property values in #jArchi
/*
* Color relations by property value
*
* Requires jArchi - https://www.archimatetool.com/blog/2018/07/02/jarchi/
*
* Original script (c) 2022 Steven Mileham
* Modifications to support relationship colorization (c) 2025 Timo Laine
*
*/
var debug = false;
@timolaine
timolaine / Mapify.ajs
Created March 11, 2025 11:39
Arranges selected elements alphabetically into a neat grid in #jArchi. The number of columns is user configurable.
/*
* Mapify
* Author: Timo Laine (timoroso.com)
* Arranges selected elements alphabetically into a neat grid.
* The number of columns is user configurable.
*/
// Get Archi's Preference Store
const archiPrefs = Java.type('com.archimatetool.editor.ArchiPlugin').PREFERENCES;
/*
* Information flows between applications
*
* This script is under construction!
*
* This script provides a list of information flows between application components.
* It is based strictly on the relationships found in the model and is therefore
* independent of views. In case more attributes for the flows are needed, they can be
* added easily (IntegrationPlatform is provided as an example).
*
@timolaine
timolaine / Insert Labels of Related Elements.ajs
Last active May 14, 2024 20:34
Insert Labels of Related Elements in Archi