From 36d646b998f8d3f195acb9ec62e9fb80efcac9d9 Mon Sep 17 00:00:00 2001 From: mitchell <70453897+667e-11@users.noreply.github.com> Date: Wed, 13 May 2015 13:33:48 -0400 Subject: Allow "#!/usr/bin/env ..." file detection; modules/textadept/file_types.lua Keep "#!.+/sh" since "#!.+sh" as a pattern is too generic. --- modules/textadept/file_types.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules') diff --git a/modules/textadept/file_types.lua b/modules/textadept/file_types.lua index fe9c3f04..81fd5041 100644 --- a/modules/textadept/file_types.lua +++ b/modules/textadept/file_types.lua @@ -30,7 +30,7 @@ M.extensions = {--[[Actionscript]]as='actionscript',asc='actionscript',--[[Ada]] -- Each pattern is matched against the first line in the file. -- @class table -- @name patterns -M.patterns = {['^#!.+/awk']='awk',['^#!.+/lua']='lua',['^#!.+/octave']='matlab',['^#!.+/perl']='perl',['^#!.+/php']='php',['^#!.+/python']='python',['^#!.+/ruby']='ruby',['^#!.+/bash']='bash',['^#!.+/sh']='bash',['^%s*class%s+%S+%s*<%s*ApplicationController']='rails',['^%s*class%s+%S+%s*<%s*ActionController::Base']='rails',['^%s*class%s+%S+%s*<%s*ActiveRecord::Base']='rails',['^%s*class%s+%S+%s*<%s*ActiveRecord::Migration']='rails',['^%s*<%?xml%s']='xml'} +M.patterns = {['^#!.+awk']='awk',['^#!.+lua']='lua',['^#!.+octave']='matlab',['^#!.+perl']='perl',['^#!.+php']='php',['^#!.+python']='python',['^#!.+ruby']='ruby',['^#!.+bash']='bash',['^#!.+/sh']='bash',['^%s*class%s+%S+%s*<%s*ApplicationController']='rails',['^%s*class%s+%S+%s*<%s*ActionController::Base']='rails',['^%s*class%s+%S+%s*<%s*ActiveRecord::Base']='rails',['^%s*class%s+%S+%s*<%s*ActiveRecord::Migration']='rails',['^%s*<%?xml%s']='xml'} --- -- List of available lexer names. -- cgit v1.2.3