annotate runtime/syntax/squid.vim @ 24880:d254f5c78b5a v8.2.2978

patch 8.2.2978: warning for uninitialized variable Commit: https://github.com/vim/vim/commit/744aecf8777e86fac6d30f072e90e2de353b8ea1 Author: Bram Moolenaar <Bram@vim.org> Date: Sat Jun 12 12:33:48 2021 +0200 patch 8.2.2978: warning for uninitialized variable Problem: Warning for uninitialized variable. Solution: Set return value to FAIL.
author Bram Moolenaar <Bram@vim.org>
date Sat, 12 Jun 2021 12:45:02 +0200
parents 46763b01cd9a
children d46f974fd69e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim syntax file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 " Language: Squid config file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Maintainer: Klaus Muth <klaus@hampft.de>
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
4 " Last Change: 2005 Jun 12
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 " URL: http://www.hampft.de/vim/syntax/squid.vim
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
6 " ThanksTo: Ilya Sher <iso8601@mail.ru>,
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
7 " Michael Dotzler <Michael.Dotzler@leoni.com>
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 323
diff changeset
10 " quit when a syntax file was already loaded
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 323
diff changeset
11 if exists("b:current_syntax")
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 " squid.conf syntax seems to be case insensitive
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 syn case ignore
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 syn keyword squidTodo contained TODO
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 syn match squidComment "#.*$" contains=squidTodo,squidTag
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 syn match squidTag contained "TAG: .*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 " Lots & lots of Keywords!
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
23 syn keyword squidConf acl always_direct announce_host announce_period
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
24 syn keyword squidConf announce_port announce_to anonymize_headers
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
25 syn keyword squidConf append_domain as_whois_server auth_param_basic
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
26 syn keyword squidConf authenticate_children authenticate_program
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
27 syn keyword squidConf authenticate_ttl broken_posts buffered_logs
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
28 syn keyword squidConf cache_access_log cache_announce cache_dir
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
29 syn keyword squidConf cache_dns_program cache_effective_group
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
30 syn keyword squidConf cache_effective_user cache_host cache_host_acl
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
31 syn keyword squidConf cache_host_domain cache_log cache_mem
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
32 syn keyword squidConf cache_mem_high cache_mem_low cache_mgr
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
33 syn keyword squidConf cachemgr_passwd cache_peer cache_peer_access
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
34 syn keyword squidConf cahce_replacement_policy cache_stoplist
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
35 syn keyword squidConf cache_stoplist_pattern cache_store_log cache_swap
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
36 syn keyword squidConf cache_swap_high cache_swap_log cache_swap_low
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
37 syn keyword squidConf client_db client_lifetime client_netmask
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
38 syn keyword squidConf connect_timeout coredump_dir dead_peer_timeout
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
39 syn keyword squidConf debug_options delay_access delay_class
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
40 syn keyword squidConf delay_initial_bucket_level delay_parameters
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
41 syn keyword squidConf delay_pools deny_info dns_children dns_defnames
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
42 syn keyword squidConf dns_nameservers dns_testnames emulate_httpd_log
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
43 syn keyword squidConf err_html_text fake_user_agent firewall_ip
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
44 syn keyword squidConf forwarded_for forward_snmpd_port fqdncache_size
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45 syn keyword squidConf ftpget_options ftpget_program ftp_list_width
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
46 syn keyword squidConf ftp_passive ftp_user half_closed_clients
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
47 syn keyword squidConf header_access header_replace hierarchy_stoplist
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
48 syn keyword squidConf high_response_time_warning high_page_fault_warning
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
49 syn keyword squidConf htcp_port http_access http_anonymizer httpd_accel
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
50 syn keyword squidConf httpd_accel_host httpd_accel_port
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
51 syn keyword squidConf httpd_accel_uses_host_header
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
52 syn keyword squidConf httpd_accel_with_proxy http_port http_reply_access
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
53 syn keyword squidConf icp_access icp_hit_stale icp_port
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
54 syn keyword squidConf icp_query_timeout ident_lookup ident_lookup_access
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
55 syn keyword squidConf ident_timeout incoming_http_average
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
56 syn keyword squidConf incoming_icp_average inside_firewall ipcache_high
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
57 syn keyword squidConf ipcache_low ipcache_size local_domain local_ip
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 syn keyword squidConf logfile_rotate log_fqdn log_icp_queries
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59 syn keyword squidConf log_mime_hdrs maximum_object_size
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 syn keyword squidConf maximum_single_addr_tries mcast_groups
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61 syn keyword squidConf mcast_icp_query_timeout mcast_miss_addr
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
62 syn keyword squidConf mcast_miss_encode_key mcast_miss_port memory_pools
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
63 syn keyword squidConf memory_pools_limit memory_replacement_policy
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
64 syn keyword squidConf mime_table min_http_poll_cnt min_icp_poll_cnt
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
65 syn keyword squidConf minimum_direct_hops minimum_object_size
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
66 syn keyword squidConf minimum_retry_timeout miss_access negative_dns_ttl
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
67 syn keyword squidConf negative_ttl neighbor_timeout neighbor_type_domain
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
68 syn keyword squidConf netdb_high netdb_low netdb_ping_period
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
69 syn keyword squidConf netdb_ping_rate never_direct no_cache
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
70 syn keyword squidConf passthrough_proxy pconn_timeout pid_filename
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
71 syn keyword squidConf pinger_program positive_dns_ttl prefer_direct
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
72 syn keyword squidConf proxy_auth proxy_auth_realm query_icmp quick_abort
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
73 syn keyword squidConf quick_abort quick_abort_max quick_abort_min
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
74 syn keyword squidConf quick_abort_pct range_offset_limit read_timeout
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
75 syn keyword squidConf redirect_children redirect_program
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
76 syn keyword squidConf redirect_rewrites_host_header reference_age
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
77 syn keyword squidConf reference_age refresh_pattern reload_into_ims
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
78 syn keyword squidConf request_body_max_size request_size request_timeout
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
79 syn keyword squidConf shutdown_lifetime single_parent_bypass
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
80 syn keyword squidConf siteselect_timeout snmp_access
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
81 syn keyword squidConf snmp_incoming_address snmp_port source_ping
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
82 syn keyword squidConf ssl_proxy store_avg_object_size
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
83 syn keyword squidConf store_objects_per_bucket strip_query_terms
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
84 syn keyword squidConf swap_level1_dirs swap_level2_dirs
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
85 syn keyword squidConf tcp_incoming_address tcp_outgoing_address
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
86 syn keyword squidConf tcp_recv_bufsize test_reachability udp_hit_obj
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
87 syn keyword squidConf udp_hit_obj_size udp_incoming_address
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
88 syn keyword squidConf udp_outgoing_address unique_hostname
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
89 syn keyword squidConf unlinkd_program uri_whitespace useragent_log
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
90 syn keyword squidConf visible_hostname wais_relay wais_relay_host
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
91 syn keyword squidConf wais_relay_port
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
92
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
93 syn keyword squidOpt proxy-only weight ttl no-query default
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
94 syn keyword squidOpt round-robin multicast-responder
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
95 syn keyword squidOpt on off all deny allow
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
96 syn keyword squidopt via parent no-digest heap lru realm
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
97 syn keyword squidopt children credentialsttl none disable
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
98 syn keyword squidopt offline_toggle diskd q1 q2
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
99
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
100 " Security Actions for cachemgr_passwd
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
101 syn keyword squidAction shutdown info parameter server_list
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
102 syn keyword squidAction client_list
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
103 syn match squidAction "stats/\(objects\|vm_objects\|utilization\|ipcache\|fqdncache\|dns\|redirector\|io\|reply_headers\|filedescriptors\|netdb\)"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
104 syn match squidAction "log\(/\(status\|enable\|disable\|clear\)\)\="
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
105 syn match squidAction "squid\.conf"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
106
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
107 " Keywords for the acl-config
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
108 syn keyword squidAcl url_regex urlpath_regex referer_regex port proto
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
109 syn keyword squidAcl req_mime_type rep_mime_type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
110 syn keyword squidAcl method browser user src dst
323
03b3684919e3 updated for version 7.0084
vimboss
parents: 7
diff changeset
111 syn keyword squidAcl time dstdomain ident snmp_community
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
112
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
113 syn match squidNumber "\<\d\+\>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
114 syn match squidIP "\<\d\{1,3}\.\d\{1,3}\.\d\{1,3}\.\d\{1,3}\>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
115 syn match squidStr "\(^\s*acl\s\+\S\+\s\+\(\S*_regex\|re[pq]_mime_type\|browser\|_domain\|user\)\+\s\+\)\@<=.*" contains=squidRegexOpt
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
116 syn match squidRegexOpt contained "\(^\s*acl\s\+\S\+\s\+\S\+\(_regex\|_mime_type\)\s\+\)\@<=[-+]i\s\+"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
117
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
118 " All config is in one line, so this has to be sufficient
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
119 " Make it fast like hell :)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
120 syn sync minlines=3
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
121
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
122 " Define the default highlighting.
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 323
diff changeset
123 " Only when an item doesn't have highlighting yet
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
124
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
125 hi def link squidTodo Todo
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
126 hi def link squidComment Comment
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
127 hi def link squidTag Special
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
128 hi def link squidConf Keyword
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
129 hi def link squidOpt Constant
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
130 hi def link squidAction String
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
131 hi def link squidNumber Number
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
132 hi def link squidIP Number
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
133 hi def link squidAcl Keyword
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
134 hi def link squidStr String
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
135 hi def link squidRegexOpt Special
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
136
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
137
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
138 let b:current_syntax = "squid"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
139
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
140 " vim: ts=8