gitinspector/extensions.py

37 lines
1.1 KiB
Python
Raw Normal View History

2012-05-04 11:40:30 +02:00
# coding: utf-8
#
# Copyright © 2012 Ejwa Software. All rights reserved.
#
# This file is part of gitinspector.
#
# gitinspector is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# gitinspector is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with gitinspector. If not, see <http://www.gnu.org/licenses/>.
__default_extensions__ = ["java", "c", "cpp", "h", "hpp", "py", "glsl", "rb", "js", "sql"]
__extensions__ = __default_extensions__
__located_extensions__ = set()
2012-05-04 11:40:30 +02:00
def get():
return __extensions__
2012-05-04 11:40:30 +02:00
def define(string):
global __extensions__
__extensions__ = string.split(",")
2012-05-04 11:40:30 +02:00
def add_located(string):
if len(string) > 0:
__located_extensions__.add(string)
2012-05-04 11:40:30 +02:00
def get_located():
return __located_extensions__