Skip to content

Instantly share code, notes, and snippets.

Avatar

DriveQuantPublic

View GitHub Profile
View drivekit-module-name-migration.sh
#!/bin/bash
modules=(DriveKitNetworking DriveKitCore DriveKitDBTripAccess DriveKitDBAchievementAccess DriveKitDBVehicleAccess DriveKitDriverData DriveKitTripAnalysis DriveKitDriverAchievement DriveKitVehicle)
for module in ${modules[@]}
do
find . -type f -not -path '*Pods*' -name "**.swift" -print0 | xargs -0 sed -i '' "s/import ${module}$/import ${module}Module/g"
find . -type f -not -path '*Pods*' -name "**.h" -print0 | xargs -0 sed -i '' "s/import ${module}$/import ${module}Module/g"
find . -type f -not -path '*Pods*' -name "**.m" -print0 | xargs -0 sed -i '' "s/import ${module}$/import ${module}Module/g"
done