Last active
November 9, 2022 11:49
-
-
Save ElectricCoffee/ed4f241874aaf4db491b90b901d8a48e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use 5.30.0; | |
use warnings; | |
use Cwd 'getcwd'; | |
use File::Basename; | |
my $dir = getcwd; | |
my ($name) = File::Basename::fileparse($dir); | |
sub update { | |
system 'pod install'; | |
exit; | |
} | |
if ($name eq 'ios') { | |
update; | |
} | |
if (-d "$dir/ios") { | |
chdir 'ios'; | |
update; | |
} | |
print STDERR <<END; | |
The folder "$dir" is not a project ios folder, nor does it have one as its immediate child! | |
Are you sure you're in the right place?" | |
END |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment