Skip to content

Commit

Permalink
First alpha version.
Browse files Browse the repository at this point in the history
  • Loading branch information
voldien committed Jul 3, 2020
1 parent dcc24d3 commit e31c442
Show file tree
Hide file tree
Showing 38 changed files with 1,874 additions and 5 deletions.
18 changes: 18 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Properly detect languages on Github
*.h linguist-language=cpp
*.inc linguist-language=cpp
*.cs linguist-language=csharps
*.sh linguist-language=shell
thirdparty/* linguist-vendored

# Normalize EOL for all files that Git considers text files
* text=auto eol=lf

# The above only works properly for Git 2.10+, so for older versions
# we need to manually list the binary files we don't want modified.
*.icns binary
*.ico binary
*.png binary
*.ttf binary
*.mp4 binary
*.kra binary
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
## [0.0.1] - 2020-05-05
### Init Release
- Added multitarget support
- Added Export And Import capabilities.
- Unique title for each target.
- Run target from unity.
7 changes: 7 additions & 0 deletions CHANGELOG.md.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

43 changes: 43 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
CMAKE_MINIMUM_REQUIRED(VERSION 3.7.2)
PROJECT(BuilderConfig None)
# Only UNIX systems.
SET(VERSION_MAJOR 0)
SET(VERSION_MINOR 1)
SET(VERSION_REVISION 0)
SET(VERSION_STATE a)
SET(VERSION ${VERSION_MAJOR}.${VERSION_MINOR}${VERSION_STATE}${VERSION_REVISION} )
IF( UNIX )
Find_PACKAGE(UnixCommands REQUIRED)

# Create distribution tarball.
SET( TARGETDIR "${PROJECT_NAME}-${VERSION}")
ADD_CUSTOM_TARGET( distribution
COMMENT "Creating distrubtion file."
COMMAND mkdir -p ${TARGETDIR}
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/Editor
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/build.sh
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/package.json
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/README.md
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/CHANGELOG.md
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/Tests
${TARGETDIR}
COMMAND ${TAR} cf - ${TARGETDIR} | ${GZIP} -c > ${TARGETDIR}.tar.gz
COMMAND ${RM} -r ${TARGETDIR} )

# Create source distribution tarball.
SET( TARGETSOURCEDIR "${PROJECT_NAME}-Source-${VERSION}")
ADD_CUSTOM_TARGET( distribution-source
COMMENT "Creating distrubtion file."
COMMAND mkdir -p ${TARGETSOURCEDIR}
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/Editor
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/build.sh
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/package.json
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/README.md
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/CHANGELOG.md
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/Tests
COMMAND ${CP} -r ${CMAKE_CURRENT_SOURCE_DIR}/LICENSE
${TARGETSOURCEDIR}
COMMAND ${TAR} cf - ${TARGETSOURCEDIR} | ${GZIP} -c > ${TARGETSOURCEDIR}.tar.gz
COMMAND ${RM} -r ${TARGETSOURCEDIR} )

ENDIF()
7 changes: 7 additions & 0 deletions CMakeLists.txt.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions Editor.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

51 changes: 51 additions & 0 deletions Editor/BuildTarget.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
using UnityEngine;
using UnityEditor;
using System;

namespace BuildMultiPlatform
{
[Serializable]
public class BuildTarget : ICloneable
{
[Tooltip("The name of the executable."), SerializeField]
public string title = "";
[Tooltip(""), SerializeField]
public string company = "";
[Tooltip("Relative output directory."), SerializeField]
public string outputDirectory = "";
[Tooltip("The name of the target. (Used in the editor only)")]
public string name = "";
[Tooltip("Enabled for building when invoking build all targets."), SerializeField]
public bool enabled = true;
[SerializeField, Tooltip("Use the default scenes specified by the build setting.")]
public bool useDefaultScenes = true;
[SerializeField, Tooltip("List of all scenes when using non default scenes.")]
//public SceneTargetList scenes;
public SceneAsset[] scenes = new SceneAsset[0];
[SerializeField, Tooltip("The target group.")]
public BuildTargetGroup targetGroup = BuildTargetGroup.Standalone;
[SerializeField, Tooltip("Specified target.")]
public UnityEditor.BuildTarget target = UnityEditor.BuildTarget.StandaloneLinux64;
[SerializeField, Tooltip("Build options.")]
public BuildOptions options = BuildOptions.None;


public string Title { get { if (this.title.Length == 0) return PlayerSettings.productName; else return this.title; } }
public object Clone()
{
BuildTarget copy = new BuildTarget();
copy.title = this.title;
copy.company = this.company;
copy.enabled = this.enabled;
copy.outputDirectory = this.outputDirectory;
copy.name = this.name;
copy.target = this.target;
copy.targetGroup = this.targetGroup;
copy.useDefaultScenes = this.useDefaultScenes;
copy.options = this.options;
copy.scenes = (SceneAsset[])this.scenes.Clone();
return (object)copy;
}
}

}
11 changes: 11 additions & 0 deletions Editor/BuildTarget.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit e31c442

Please sign in to comment.