batchmode에서 안됨

    public static void SetCloudProjectId(string id, string name, string company)
    {
        var type = Type.GetType("UnityEditor.Connect.UnityConnect, UnityEditor, Version = 0.0.0.0, Culture = neutral, PublicKeyToken = null");
        PropertyInfo instanceInfo = type.GetProperty("instance");
        object settingsInstance = instanceInfo.GetValue(null, null);

        MethodInfo unbind = type.GetMethod("UnbindProject");
        MethodInfo bind = type.GetMethod("BindProject");

        Debug.Log("Unbinding current cloud project");
        unbind.Invoke(settingsInstance, new System.Object[] { });

        Debug.LogFormat("Binding cloud project to {0}: {1} ({2})", name, id, company);
        bind.Invoke(settingsInstance, new System.Object[] { id, name, company });

        Debug.LogFormat("Binded cloud project to {0}: {1} ({2})", name, id, company);
    }

실행후에 유니티 재시작필요.

Jenkins에서 호출하는경우 빌드전에 따로 실행

유니티 Bind를 사용하는 경우 batch mode에서 제대로 안되서 파일 직접변경이 필요.

    public static void SetCloudProjectIdFile(string name, string id, string company)
    {
        const string filepath = "ProjectSettings/ProjectSettings.asset";
        string[] lines = File.ReadAllLines(filepath);
        var new_lines = new List<string>();
        id = " " + id;
        name = " " + name;
        company = " " + company;

        foreach (string line in lines)
        {
            string[] command = line.Split(':');
            if (command.Length < 2)
            {
                new_lines.Add(line);
                continue;
            }

            switch (command[0])
            {
                case "  cloudProjectId":
                    if (command[1] != id)
                    {
                        Debug.Log($"Replace {command[0]}");
                        new_lines.Add(string.Join(":", command[0], id));
                    }
                    break;

                case "  projectName":
                    if (command[1] != name)
                    {
                        Debug.Log($"Replace {command[0]}");
                        new_lines.Add(string.Join(":", command[0], name));
                    }
                    break;

                case "  organizationId":
                    if (command[1] != company)
                    {
                        Debug.Log($"Replace {command[0]}");
                        new_lines.Add(string.Join(":", command[0], company));
                    }
                    break;

                default:
                    new_lines.Add(line);
                    break;
            }
        }

        File.WriteAllLines(filepath, new_lines.ToArray());
        AssetDatabase.Refresh();
    }

rm -f play.prop
touch play.prop

echo GIT_COMMIT_SHORT=$(git rev-parse --short ${GIT_COMMIT}) > play.prop
echo GIT_REVISION=$(git rev-list --count ${GIT_COMMIT}) >> play.prop

vi lib/redmine/scm/adapters/subversion_adapter.rb 

str << " --no-auth-cache --non-interactive --config-dir /tmp/subversion_config"


svn ls --config-option config:auth:store-auth-creds=yes --config-dir /tmp/subversion_config https://192.168.0.230/svn/project/trunk


ruby bin/rails runner "Repository.fetch_changesets" -e production


http://www.redmine.org/issues/1273

'자료 > Article' 카테고리의 다른 글

레드마인 visual svn  (0) 2017.01.03
mysql batch job  (0) 2016.07.08
font의 facename으로 displayname및 filename얻어내기  (1) 2007.06.20
Design and Implementation of a Win32 Text Editor  (0) 2007.06.12
Utilities for STL std::string  (1) 2007.03.27
/ENTRY(진입점 기호)  (2) 2007.03.01

http://viralpatel.net/blogs/batch-insert-in-java-jdbc/

'자료 > Article' 카테고리의 다른 글

레드마인 visual svn  (0) 2017.01.03
mysql batch job  (0) 2016.07.08
font의 facename으로 displayname및 filename얻어내기  (1) 2007.06.20
Design and Implementation of a Win32 Text Editor  (0) 2007.06.12
Utilities for STL std::string  (1) 2007.03.27
/ENTRY(진입점 기호)  (2) 2007.03.01

http://visualstudiogallery.msdn.microsoft.com/8e2103b6-87cf-4fef-9410-a580c434b602

'자료 > Module' 카테고리의 다른 글

VS2012용 매크로 플러그인  (0) 2013.03.26

DECLARE @str varchar(8000)

SET @str = '10,2,3,4,5,6,7,8,9'


DECLARE @InputString varchar(8000)

SELECT @InputString = ',' + @str + ','


;with qry(n, names) as

       (select len(list.names) - len(replace(list.names, ',', '')) - 1 as n, substring(list.names, 2, len(list.names)) as names

        from (select @InputString names) as list

        union all

        select (n - 1) as n,

               substring(names, 1 + charindex(',', names), len(names)) as names

        from qry

        where n > 1)

 select substring(names, 1, charindex(',', names) - 1) dwarf

 from qry;





DECLARE @str varchar(8000)

SET @str = '10,2,3,4,5,6,7,8,9'


DECLARE @InputString varchar(8000)

SELECT @InputString = @str + ','


;WITH RecursiveCSV(x,y) 

AS 

(

    SELECT 

        x = SUBSTRING(@InputString,0,CHARINDEX(',',@InputString,0)),

        y = SUBSTRING(@InputString,CHARINDEX(',',@InputString,0)+1,LEN(@InputString))

    UNION ALL

    SELECT 

        x = SUBSTRING(y,0,CHARINDEX(',',y,0)),

        y = SUBSTRING(y,CHARINDEX(',',y,0)+1,LEN(y))

    FROM 

        RecursiveCSV 

    WHERE

        SUBSTRING(y,CHARINDEX(',',y,0)+1,LEN(y)) <> '' OR 

        SUBSTRING(y,0,CHARINDEX(',',y,0)) <> ''

)

(select x FROM RecursiveCSV)

OPTION (MAXRECURSION 32767);



http://bit.ly/X8F31C

드디어 몬스터크라이가 티스토어에 입점했습니다.

아... 서버만 죽지 말아라;;

http://www.thisisgame.com/board/view.php?id=1207208&category=102

디스이즈게임에 기사가 나갔네요.

열심히 만들고 있습니다!!




Shift-JIS 코드표 : http://www.rikai.com/library/kanjitables/kanji_codes.sjis.shtml
상용한자표 : 
http://ja.wikipedia.org/wiki/%E5%B8%B8%E7%94%A8%E6%BC%A2%E5%AD%97%E4%B8%80%E8%A6%A7

+ Recent posts