Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cocoapods
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
cocoapods
Commits
10ca8e78
Commit
10ca8e78
authored
Mar 13, 2015
by
Olivier Halligon
Committed by
AliSoftware
Apr 07, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[xcassets] Cleanup Pods-Resources.sh script
parent
8091852c
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
2 additions
and
29 deletions
+2
-29
copy_resources_script.rb
lib/cocoapods/generator/copy_resources_script.rb
+0
-26
aggregate_target_installer.rb
.../installer/target_installer/aggregate_target_installer.rb
+1
-2
cocoapods-integration-specs
spec/cocoapods-integration-specs
+1
-1
No files found.
lib/cocoapods/generator/copy_resources_script.rb
View file @
10ca8e78
...
...
@@ -83,7 +83,6 @@ module Pod
end
script
+=
RSYNC_CALL
script
+=
XCASSETS_COMPILE
script
end
...
...
@@ -127,9 +126,6 @@ install_resource()
echo "xcrun mapc
\\
"${PODS_ROOT}/$1
\\
"
\\
"${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1" .xcmappingmodel`.cdm
\\
""
xcrun mapc "${PODS_ROOT}/$1" "${CONFIGURATION_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$1" .xcmappingmodel`.cdm"
;;
*.xcassets)
XCASSET_FILES="$XCASSET_FILES '${PODS_ROOT}/$1'"
;;
/*)
echo "$1"
echo "$1" >> "$RESOURCES_TO_COPY"
...
...
@@ -151,28 +147,6 @@ fi
rm -f "$RESOURCES_TO_COPY"
EOS
XCASSETS_COMPILE
=
<<
EOS
if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ]
then
case "${TARGETED_DEVICE_FAMILY}" in
1,2)
TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone"
;;
1)
TARGET_DEVICE_ARGS="--target-device iphone"
;;
2)
TARGET_DEVICE_ARGS="--target-device ipad"
;;
*)
TARGET_DEVICE_ARGS="--target-device mac"
;;
esac
while read line; do XCASSET_FILES="$XCASSET_FILES '$line'"; done <<<$(find "$PWD" -name "*.xcassets" | egrep -v "^$PODS_ROOT")
echo $XCASSET_FILES | xargs actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${IPHONEOS_DEPLOYMENT_TARGET}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
fi
EOS
end
end
end
lib/cocoapods/installer/target_installer/aggregate_target_installer.rb
View file @
10ca8e78
...
...
@@ -113,9 +113,8 @@ module Pod
resources_by_config
=
{}
target
.
user_build_configurations
.
keys
.
each
do
|
config
|
file_accessors
=
library_targets
.
select
{
|
t
|
t
.
include_in_build_config?
(
config
)
}.
flat_map
(
&
:file_accessors
)
resource_paths
=
file_accessors
.
flat_map
{
|
accessor
|
accessor
.
resources
.
flat_map
{
|
res
|
res
.
relative_path_from
(
project
.
path
.
dirname
)
}
}
resource_bundles
=
file_accessors
.
flat_map
{
|
accessor
|
accessor
.
resource_bundles
.
keys
.
map
{
|
name
|
"${BUILT_PRODUCTS_DIR}/
#{
name
.
shellescape
}
.bundle"
}
}
resources_by_config
[
config
]
=
(
resource_paths
+
resource_bundles
)
.
uniq
resources_by_config
[
config
]
=
resource_bundles
.
uniq
resources_by_config
[
config
]
<<
bridge_support_file
if
bridge_support_file
end
resources_by_config
...
...
cocoapods-integration-specs
@
ae774302
Subproject commit
e35ee4d2dd475dd8407a3f3231a403a370b5d2a0
Subproject commit
ae774302d2e3d88ceb991d7e04f0d99086376257
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment