Homelab, Linux, JS & ABAP (~˘▾˘)~
 

[Home Assistant] Editor shortcuts

All VS Code shortcuts will also work in Home Assistant. I mostly need the following:

TabMove lines to right
Ctrl + Tab (on Linux Mint it’s Shit + Tab)Move lines to left
Ctrl + Alt + Mouse selectionMark area over multiple lines (works only in YAML editor)
Ctrl + Shift + KDelete row
Alt + Arrow key up or downMove row(s) up or down
Alt + Shift + Arrow downDuplicate selected rows
Ctrl + Shit + /Comment line/area

Also, you can simply expand the window you are working in, by clicking on the window title.

[CAP] CQL Expand Composition / Deep read

In the documentation they always use a star in string literals like this o => o.`*` to select all fields, but when running this it always failed. However, after some tests I found that this format works with brackets o => o.('*')

https://cap.cloud.sap/docs/guides/providing-services/#–-deep-read

entity myEntity: cuid, managed {
    field1          : String;
    comp            : Composition of one myComposition;
}
 
aspect myComposition: cuid, managed {
    myCompField: String;
}
        const result = await SELECT.from(myEntity)
            .columns(e => {
                e('*')
                e.comp(c => c.myCompField) //expand composition, but only select 'myCompField'
            })

Update 14.09.2023: is now fixed (#)