diff --git a/.gitmodules b/.gitmodules index 05a2491880..19f34147ee 100644 --- a/.gitmodules +++ b/.gitmodules @@ -533,6 +533,9 @@ [submodule "vendor/grammars/hoon-grammar"] path = vendor/grammars/hoon-grammar url = https://github.com/pkova/hoon-grammar.git +[submodule "vendor/grammars/iCalendar-sublime"] + path = vendor/grammars/iCalendar-sublime + url = https://github.com/kimsey0/iCalendar-sublime.git [submodule "vendor/grammars/ide-tools"] path = vendor/grammars/ide-tools url = https://github.com/toitware/ide-tools.git diff --git a/grammars.yml b/grammars.yml index 23c95ad2f7..6116ac88ca 100644 --- a/grammars.yml +++ b/grammars.yml @@ -444,6 +444,8 @@ vendor/grammars/holyc.tmbundle: - source.hc vendor/grammars/hoon-grammar: - source.hoon +vendor/grammars/iCalendar-sublime: +- source.iCalendar vendor/grammars/ide-tools: - source.toit vendor/grammars/idl.tmbundle: diff --git a/lib/linguist/languages.yml b/lib/linguist/languages.yml index aae547bd83..c78a9c4750 100644 --- a/lib/linguist/languages.yml +++ b/lib/linguist/languages.yml @@ -943,11 +943,11 @@ Caddyfile: type: data color: "#22b638" aliases: - - Caddy + - Caddy extensions: - - ".caddyfile" + - ".caddyfile" filenames: - - Caddyfile + - Caddyfile ace_mode: text tm_scope: source.Caddyfile language_id: 615465151 @@ -5359,7 +5359,7 @@ Pkl: extensions: - ".pkl" interpreters: - - pkl + - pkl tm_scope: source.pkl ace_mode: text language_id: 288822799 @@ -8362,6 +8362,19 @@ hoon: extensions: - ".hoon" language_id: 560883276 +iCalendar: + type: data + color: "#ec564c" + extensions: + - ".ics" + - ".ical" + tm_scope: source.iCalendar + aliases: + - iCal + ace_mode: properties + codemirror_mode: properties + codemirror_mime_type: text/x-properties + language_id: 98384424 jq: color: "#c7254e" ace_mode: text diff --git a/samples/iCalendar/2024.ics b/samples/iCalendar/2024.ics new file mode 100644 index 0000000000..051b70e45c --- /dev/null +++ b/samples/iCalendar/2024.ics @@ -0,0 +1,121 @@ +BEGIN:VCALENDAR +VERSION:2.0 +METHOD:PUBLISH +CLASS:PUBLIC +X-WR-CALDESC:中国法定节假日数据,自动每日抓取国务院公 + 告。 +X-WR-CALNAME:中国法定节假日 +BEGIN:VTIMEZONE +TZID:Asia/Shanghai +BEGIN:STANDARD +DTSTART;VALUE=DATE-TIME:19700101T000000 +TZOFFSETFROM:+0800 +TZOFFSETTO:+0800 +END:STANDARD +END:VTIMEZONE +BEGIN:VEVENT +SUMMARY:元旦假期 +DTSTART;VALUE=DATE:20240101 +DTEND;VALUE=DATE:20240102 +DTSTAMP;VALUE=DATE:20240101 +UID:2024-01-01/2024-01-02/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:上班(补春节假期) +DTSTART;VALUE=DATE:20240204 +DTEND;VALUE=DATE:20240205 +DTSTAMP;VALUE=DATE:20240204 +UID:2024-02-04/2024-02-05/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:春节假期 +DTSTART;VALUE=DATE:20240210 +DTEND;VALUE=DATE:20240218 +DTSTAMP;VALUE=DATE:20240210 +UID:2024-02-10/2024-02-18/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:上班(补春节假期) +DTSTART;VALUE=DATE:20240218 +DTEND;VALUE=DATE:20240219 +DTSTAMP;VALUE=DATE:20240218 +UID:2024-02-18/2024-02-19/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:清明节假期 +DTSTART;VALUE=DATE:20240404 +DTEND;VALUE=DATE:20240407 +DTSTAMP;VALUE=DATE:20240404 +UID:2024-04-04/2024-04-07/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:上班(补清明节假期) +DTSTART;VALUE=DATE:20240407 +DTEND;VALUE=DATE:20240408 +DTSTAMP;VALUE=DATE:20240407 +UID:2024-04-07/2024-04-08/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:上班(补劳动节假期) +DTSTART;VALUE=DATE:20240428 +DTEND;VALUE=DATE:20240429 +DTSTAMP;VALUE=DATE:20240428 +UID:2024-04-28/2024-04-29/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:劳动节假期 +DTSTART;VALUE=DATE:20240501 +DTEND;VALUE=DATE:20240506 +DTSTAMP;VALUE=DATE:20240501 +UID:2024-05-01/2024-05-06/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:上班(补劳动节假期) +DTSTART;VALUE=DATE:20240511 +DTEND;VALUE=DATE:20240512 +DTSTAMP;VALUE=DATE:20240511 +UID:2024-05-11/2024-05-12/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:端午节假期 +DTSTART;VALUE=DATE:20240610 +DTEND;VALUE=DATE:20240611 +DTSTAMP;VALUE=DATE:20240610 +UID:2024-06-10/2024-06-11/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:上班(补中秋节假期) +DTSTART;VALUE=DATE:20240914 +DTEND;VALUE=DATE:20240915 +DTSTAMP;VALUE=DATE:20240914 +UID:2024-09-14/2024-09-15/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:中秋节假期 +DTSTART;VALUE=DATE:20240915 +DTEND;VALUE=DATE:20240918 +DTSTAMP;VALUE=DATE:20240915 +UID:2024-09-15/2024-09-18/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:上班(补国庆节假期) +DTSTART;VALUE=DATE:20240929 +DTEND;VALUE=DATE:20240930 +DTSTAMP;VALUE=DATE:20240929 +UID:2024-09-29/2024-09-30/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:国庆节假期 +DTSTART;VALUE=DATE:20241001 +DTEND;VALUE=DATE:20241008 +DTSTAMP;VALUE=DATE:20241001 +UID:2024-10-01/2024-10-08/NateScarlet/holiday-cn +END:VEVENT +BEGIN:VEVENT +SUMMARY:上班(补国庆节假期) +DTSTART;VALUE=DATE:20241012 +DTEND;VALUE=DATE:20241013 +DTSTAMP;VALUE=DATE:20241012 +UID:2024-10-12/2024-10-13/NateScarlet/holiday-cn +END:VEVENT +END:VCALENDAR diff --git a/samples/iCalendar/todo-2.ical b/samples/iCalendar/todo-2.ical new file mode 100644 index 0000000000..349841e977 --- /dev/null +++ b/samples/iCalendar/todo-2.ical @@ -0,0 +1,17 @@ +BEGIN:VCALENDAR +PRODID:-//K Desktop Environment//NONSGML KOrganizer 5.18.2 (21.08.2)//EN +VERSION:2.0 +X-KDE-ICAL-IMPLEMENTATION-VERSION:1.0 +BEGIN:VTODO +ORGANIZER;CN=Stable:MAILTO:gjDitchfield@acm.org +DTSTAMP:20210922T202815Z +CREATED:20210922T202800Z +UID:c962d358-f448-43fc-ac2f-4a629625a7a9 +SEQUENCE:1 +LAST-MODIFIED:20210922T202815Z +SUMMARY:completed to-do +COMPLETED:20210922T202815Z +PERCENT-COMPLETE:100 +STATUS:COMPLETED +END:VTODO +END:VCALENDAR diff --git a/vendor/README.md b/vendor/README.md index bb42a892d3..54b0d15dc2 100644 --- a/vendor/README.md +++ b/vendor/README.md @@ -659,6 +659,7 @@ This is a list of grammars that Linguist selects to provide syntax highlighting - **edn:** [atom/language-clojure](https://github.com/atom/language-clojure) - **fish:** [l15n/fish-tmbundle](https://github.com/l15n/fish-tmbundle) - **hoon:** [pkova/hoon-grammar](https://github.com/pkova/hoon-grammar) +- **iCalendar:** [kimsey0/iCalendar-sublime](https://github.com/kimsey0/iCalendar-sublime) - **jq:** [wader/language-jq](https://github.com/wader/language-jq) - **kvlang:** [p0lygun/kivy-language-grammer](https://github.com/p0lygun/kivy-language-grammer) - **mIRC Script:** [gen-angry/language-msl](https://github.com/gen-angry/language-msl) diff --git a/vendor/grammars/iCalendar-sublime b/vendor/grammars/iCalendar-sublime new file mode 160000 index 0000000000..ee1aaa8a96 --- /dev/null +++ b/vendor/grammars/iCalendar-sublime @@ -0,0 +1 @@ +Subproject commit ee1aaa8a96cc72c45be5dbbb02ec8f994a414e23 diff --git a/vendor/licenses/git_submodule/iCalendar-sublime.dep.yml b/vendor/licenses/git_submodule/iCalendar-sublime.dep.yml new file mode 100644 index 0000000000..c1e684f575 --- /dev/null +++ b/vendor/licenses/git_submodule/iCalendar-sublime.dep.yml @@ -0,0 +1,33 @@ +--- +name: iCalendar-sublime +version: ee1aaa8a96cc72c45be5dbbb02ec8f994a414e23 +type: git_submodule +homepage: https://github.com/kimsey0/iCalendar-sublime.git +license: mit +licenses: +- sources: LICENSE + text: |+ + The MIT License (MIT) + + Copyright (c) 2015 kimsey0 + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + SOFTWARE. + +notices: [] +...