12345678910111213141516171819202122232425262728 |
- #!/bin/bash
- # copy icons
- #
- run_icons()
- {
- local _name="${1-master}"
- local _dir="${2-$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)}"
- local _target="${_dir%/*}" # deleted slash
- local _src="${_target%scripts}/src/images/icons/${_name}.svg" # input
- local _dest="${_target%scripts}/dist/images/icons/" # output
- # copy master.svg
- if [[ -n "${_src}" ]];
- then
- rm -rfv "${_dest}"
- mkdir -p "${_dest}"
- cp -fv "${_src}" "${_dest}"
- fi
- }
- # ==============================================================================
- # EXECUTION - START
- # ==============================================================================
- run_icons "$@"
|