You've already forked macports-base
mirror of
https://github.com/macports/macports-base.git
synced 2026-07-12 18:18:43 -07:00
Not-yet-working portextract
git-svn-id: https://svn.macports.org/repository/macports/trunk/base@27 d073be05-634f-4543-b044-5fe20cf6d1d6
This commit is contained in:
+23
-1
@@ -7,8 +7,30 @@ namespace eval portextract {
|
||||
variable options
|
||||
}
|
||||
|
||||
# define globals
|
||||
globals portextract::options
|
||||
|
||||
# define options
|
||||
options portextract::options extract_only extract_command extract_before_args extract_after_args
|
||||
|
||||
proc portextract::main {args} {
|
||||
global portname
|
||||
global portname workdir distfiles
|
||||
|
||||
# Set up defaults
|
||||
default portextract::options extract_only $distfiles
|
||||
default portextract::options extract_cmd gzip
|
||||
default portextract::options extract_before_args -dc
|
||||
default portextract::options extract_after_args "|tar -xf -"
|
||||
|
||||
set portdir [pwd]
|
||||
|
||||
if [file exists $workdir] {
|
||||
file delete -force $workdir
|
||||
}
|
||||
|
||||
file mkdir $workdir
|
||||
cd $workdir
|
||||
|
||||
puts "Extracting port: $portname"
|
||||
return 0
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user