Closed pokey closed 5 days ago
@pokey @knausj85 I've created a solution where we are back to a single line header for each language. This time using a tag.
tag: user.typescript
-
https://github.com/AndreasArvidsson/andreas-talon/blob/master/langs/javascript/typescript.talon https://github.com/AndreasArvidsson/andreas-talon/blob/master/misc/language_mode/language_mode.py
I have now made a pr to update the programming languages to use tags instead
The problem
We have had issues in the past where commands are unexpectedly active in sleep mode, eg #561. The problem is that if you put
mode:
in a.talon
file header, you disable the implicitmode: command
, which in turn allows you to enable the file during sleep accidentally.A quick search reveals that we still have some commands active in sleep mode for this reason. See eg go.talon, which results in
go
commands being active if talon is sleeping while you have ago
file open.The solution
We may want to prefer using tags in many of the places that we use modes today. For example, the following modes are good candidates to become tags:
user.homophones
user.windbg
user.help
user.help_scope
On the other hand, things like "game" or "solo" would be examples of good, general modes, because a mode should ideally be very transformative of the command set and make sense when enabled by itself.