Skip to content

Commit f2d8046

Browse files
authored
Merge pull request #63 from SublimeText/feature/laundry
Various cleanups for the next release, grouped in a single PR
2 parents 9d53736 + 374fe45 commit f2d8046

8 files changed

+46
-4627
lines changed

CHANGELOG.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,35 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66

77
## Unreleased
88

9+
### Added
10+
11+
- Declare hyphens as sub-word separators.
12+
- Special highlighting for `for_each` and `count` meta arguments.
13+
- Highlighting of more special language variables: `each`, `count` and `self`.
14+
15+
### Changed
16+
17+
- Switch to Syntax version 2. This breaks compatibility with ST builds before 4000!
18+
- Adapt and improve many scope names to standards that have been established
19+
over the past years for the default packages,
20+
including:
21+
* String interpolation meta scopes and punctuation
22+
* Keywords (declarations and `in` inside a `for` expression)
23+
* Attribute access punctuation
24+
* Punctuation scopes in `for` expressions
25+
- Updated the built-in function list for highlighting.
26+
27+
### Removed
28+
29+
- Various files targetting older ST versions,
30+
notably the old `.tmLanguage` syntax definition.
31+
32+
### Fixed
33+
34+
- Improved matching of identifiers by adding a scope and properly recognizing hyphens.
35+
36+
---
37+
938
## v1.0.0 - 2020-01-20
1039

1140
A huge thanks to @patrickrgaffney for this amazing contribution. [#39](https://github.com/alexlouden/Terraform.tmLanguage/pull/39)

HCL.sublime-settings

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
{
22
"tab_size": 2,
3-
"translate_tabs_to_spaces": true
3+
"translate_tabs_to_spaces": true,
4+
// Move '-' to sub-word separators
5+
"word_separators": "./\\()\"':,.;<>~!@#$%^&*|+=[]{}`~?",
6+
"sub_word_separators": "_-",
47
}

LICENSE

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
MIT License
22

33
Copyright (c) 2016 Alex Louden
4+
Copyright (c) 2024 FichteFoll <fichtefoll2@googlemail.com>
45

56
Permission is hereby granted, free of charge, to any person obtaining a copy
67
of this software and associated documentation files (the "Software"), to deal
@@ -18,4 +19,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1819
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
1920
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2021
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21-
SOFTWARE.
22+
SOFTWARE.

README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
Terraform Syntax Highlighting And Snippets
22
==========================================
33

4-
Basic support for Terraform's [custom .tf file type](http://www.terraform.io/docs/configuration/syntax.html), along with snippets for each of the basic Terraform resource types.
5-
4+
This [Sublime Text](https://sublimetext.com/) package
5+
provides basic support for Terraform's [custom `.tf` file type](http://www.terraform.io/docs/configuration/syntax.html),
6+
along with snippets for each of the basic Terraform resource types.
67

78
![screenshot](screenshot.png)
89

@@ -12,15 +13,15 @@ Installation
1213

1314
### Using Package Control
1415

15-
1. Having [Package Control](https://packagecontrol.io/installation) installed
16+
1. Install [Package Control](https://packagecontrol.io/installation), if needed.
1617
2. Open the palette by pressing `Ctrl+Shift+P` (Win, Linux) or `Cmd+Shift+P` (OS X).
1718
3. Select _"Package Control: Install package"_
1819
4. Select _"Terraform"_
1920

2021
### Manually
2122

2223
1. Open the Sublime Text Packages folder
23-
- OS X: `~/Library/Application Support/Sublime Text 3/Packages/`
24-
- Windows: `%APPDATA%/Sublime Text 3/Packages/`
25-
- Linux (Ubuntu/Debian): `~/.config/sublime-text-3/Packages/`
24+
- OS X: `~/Library/Application Support/Sublime Text/Packages/`
25+
- Windows: `%APPDATA%/Sublime Text/Packages/`
26+
- Linux (Ubuntu/Debian): `~/.config/sublime-text/Packages/`
2627
2. Clone this repo

Terraform-vars.sublime-settings

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
{
22
"tab_size": 2,
3-
"translate_tabs_to_spaces": true
3+
"translate_tabs_to_spaces": true,
4+
// Move '-' to sub-word separators
5+
"word_separators": "./\\()\"':,.;<>~!@#$%^&*|+=[]{}`~?",
6+
"sub_word_separators": "_-",
47
}

0 commit comments

Comments
 (0)