Skip to content

Commit

Permalink
Updating configuration files to work with new YAML based config
Browse files Browse the repository at this point in the history
  • Loading branch information
tpoveda committed Oct 26, 2019
1 parent 133523b commit a2e9e26
Show file tree
Hide file tree
Showing 5 changed files with 64 additions and 101 deletions.
70 changes: 0 additions & 70 deletions artellapipe/config/__init__.py
Original file line number Diff line number Diff line change
@@ -1,70 +0,0 @@
#! /usr/bin/env python
# -*- coding: utf-8 -*-

"""
Initialization module for artellapipe-config
"""

from __future__ import print_function, division, absolute_import

__author__ = "Tomas Poveda"
__license__ = "MIT"
__maintainer__ = "Tomas Poveda"
__email__ = "tpovedatd@gmail.com"

import os
import inspect


class ArtellaConfigs(object):

CHANGELOG_FILE_NAME = 'changelog.yml'
CONFIG_FILE_NAME = 'config.yml'
NAMING_FILE_NAME = 'naming.yml'

def get_configurations_path(self):
"""
Returns path where tpNameIt module is stored
:return: str
"""

try:
mod_dir = os.path.dirname(inspect.getframeinfo(inspect.currentframe()).filename)
except Exception:
try:
mod_dir = os.path.dirname(__file__)
except Exception:
try:
import tpDccLib
mod_dir = tpDccLib.__path__[0]
except Exception:
return None

return mod_dir

def get_changelog_file(self):
"""
Returns path where changelog file is located
:return: str
"""

from tpPyUtils import path as path_utils
return path_utils.clean_path(os.path.join(self.get_configurations_path(), self.CHANGELOG_FILE_NAME))

def get_project_configuration_file(self):
"""
Returns path where project configuration file is located
:return: str
"""

from tpPyUtils import path as path_utils
return path_utils.clean_path(os.path.join(self.get_configurations_path(), self.CONFIG_FILE_NAME))

def get_naming_file(self):
"""
Returns path where naming rules file is located
:return: str
"""

from tpPyUtils import path as path_utils
return path_utils.clean_path(os.path.join(self.get_configurations_path(), self.NAMING_FILE_NAME))
59 changes: 59 additions & 0 deletions artellapipe/config/artellapipe-launcher-plugins-dccselector.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# Base Configuration file for artellapipe-launcher-plugins-dccselector

maya:
enabled: False
icon: color/maya
supported_versions: []
default_version: ""
departments: []
plugins: {}

3ds max:
enabled: False
icon: color/maya
supported_versions: []
default_version: ""
departments: []
plugins: {}

nuke:
enabled: False
icon: color/maya
supported_versions: []
default_version: ""
departments: []

houdini:
enabled: False
icon: color/maya
supported_versions: []
default_version: ""
departments: []

photoshop:
enabled: False
icon: color/maya
supported_versions: []
default_version: ""
departments: []

zbrush:
enabled: False
icon: color/maya
supported_versions: []
default_version: ""
departments: []

substance painter:
enabled: False
icon: color/maya
supported_versions: []
default_version: ""
departments: []

substance designer:
enabled: False
icon: color/maya
supported_versions: []
default_version: ""
departments: []
5 changes: 5 additions & 0 deletions artellapipe/config/artellapipe-launcher.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Base Configuration file for artellapipe-launcher

version: 0.0.0
name: Artella
plugins: []
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# Base Configuration for Artella Projects

# Define configuration variables for project
project:
name: ${title}
env_var: ${project_upper + "_PROJECT"}
Expand Down
30 changes: 0 additions & 30 deletions artellapipe/config/config.json

This file was deleted.

0 comments on commit a2e9e26

Please sign in to comment.