Add Dynamic Application Factory
This enabled realtime dependency injection for the fflib application. By default the configuration comes from the Custom Metadata object fflib_AppBinding__mdt, but can be fully customised and extended. Initial stuff
This commit is contained in:
@@ -0,0 +1,87 @@
|
||||
#!/bin/bash
|
||||
#<%%#
|
||||
####################################################################################################
|
||||
#
|
||||
# FILENAME: local-config-template.sh.ejs
|
||||
#
|
||||
# PURPOSE: Template for creating a personalized local-config.sh file.
|
||||
#
|
||||
# DESCRIPTION: All shell scripts in the dev-tools directory require several configuration values
|
||||
# to run correctly (eg. the path to your project's root directory or the alias of
|
||||
# the DevHub that you want to use. These customizations can be specific to each
|
||||
# individual developer, and therefore should not be tracked by the project's VCS.
|
||||
#
|
||||
# This file serves as a template that Release Managers can use to establish baseline
|
||||
# values for their project. When individaul developers clone the repo and initialize
|
||||
# their local, personal version of the project this template is used to create a
|
||||
# customized local-config.sh file at <project-root>/dev-tools/lib/local-config.sh
|
||||
#
|
||||
# INSTRUCTIONS: 1. Inside of the dev-tools directory, execute the following command
|
||||
# cp ./templates/local-config-template.sh.ejs ./lib/local-config.sh
|
||||
# 2. Edit the default values in your local-config.sh to meet the needs of your local
|
||||
# environment and project setup.
|
||||
#
|
||||
####################################################################################################
|
||||
#%>
|
||||
##
|
||||
###
|
||||
#### DEFINE LOCAL CONFIGURATION VARIABLES ##########################################################
|
||||
###
|
||||
##
|
||||
#
|
||||
# Alias for the Dev Hub that should be used when creating scratch orgs for this project.
|
||||
# This variable will always need to be customized for individual developers.
|
||||
DEV_HUB_ALIAS="<%%-userAnswers.devHubAlias%>"
|
||||
|
||||
# Namespace Prefix. Set to empty string ("") if this project is not building a managed package.
|
||||
NAMESPACE_PREFIX="<%-userAnswers.namespacePrefix%>"
|
||||
|
||||
# Package Name. Specified as part of the Package Detail info in your packaging org.
|
||||
# Surround this value with double-quotes if your package name contains space characters.
|
||||
# Set to empty string ("") if this project is not building a managed package.
|
||||
PACKAGE_NAME="<%-userAnswers.packageName%>"
|
||||
|
||||
# Metadata Package ID. Refers to the metadata package as a whole. Must begin with "033".
|
||||
# Set to empty string ("") if this project is not building a managed package.
|
||||
METADATA_PACKAGE_ID="<%-userAnswers.metadataPackageId%>"
|
||||
|
||||
# Package Version ID. Refers to a specific, installable version of a package. Must begin with "04t".
|
||||
# Set to empty string ("") if this project is not building a managed package.
|
||||
PACKAGE_VERSION_ID="<%-userAnswers.packageVersionId%>"
|
||||
|
||||
# Default Package Directory. Should match what is set in sfdx-project.json.
|
||||
DEFAULT_PACKAGE_DIR_NAME="<%-userAnswers.packageDirectory%>"
|
||||
|
||||
# Alias for the primary Scratch Org used by this project.
|
||||
SCRATCH_ORG_ALIAS="$NAMESPACE_PREFIX-SCRATCH"
|
||||
|
||||
# Alias for the packaging org for this project.
|
||||
PACKAGING_ORG_ALIAS="$NAMESPACE_PREFIX-PACKAGE"
|
||||
|
||||
# Alias for the subscriber test org used to test managed-beta package installs.
|
||||
SUBSCRIBER_ORG_ALIAS="$NAMESPACE_PREFIX-SUBSCRIBER"
|
||||
|
||||
# Git Remote URI. SSH or HTTPS URI that points to the Git remote repo used by this project.
|
||||
# GitHub is used as an example here, but any Git remote (ie. BitBucket) can be used.
|
||||
# Set to empty string ("") if this project is not being tracked in a remote repository.
|
||||
GIT_REMOTE_URI="<%-userAnswers.gitRemoteUri%>"
|
||||
|
||||
# Location of the primary scratch-def.json file that should be used by SFDX-Falcon scripts that
|
||||
# create scratch orgs (eg. rebuild-scratch-org).
|
||||
SCRATCH_ORG_CONFIG="$PROJECT_ROOT/config/project-scratch-def.json"
|
||||
|
||||
# Echo the variables set by this script prior to exiting. Specify "false" to suppress the
|
||||
# display of local config that normally occurs when executing SFDX-Falcon based scripts.
|
||||
ECHO_LOCAL_CONFIG_VARS="true"
|
||||
#
|
||||
##
|
||||
###
|
||||
#### ECHO ALL VARIABLES ############################################################################
|
||||
###
|
||||
##
|
||||
#
|
||||
if [ "$ECHO_LOCAL_CONFIG_VARS" = "true" ]; then
|
||||
echo "\n`tput setaf 7``tput bold`Local configuration variables set by `dirname $0`/lib/local-config.sh`tput sgr0`\n"
|
||||
echoConfigVariables
|
||||
fi
|
||||
##END##
|
||||
Reference in New Issue
Block a user