Добавил проверку пакета Img. И поправил проверку типов изображений
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 1m23s
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 1m23s
This commit is contained in:
20
projman.tcl
20
projman.tcl
@@ -1,6 +1,6 @@
|
||||
#!/bin/sh
|
||||
# Tcl ignores the next line -*- tcl -*- \
|
||||
exec wish8.6 "$0" -- "$@"
|
||||
exec wish9.0 "$0" -- "$@"
|
||||
|
||||
######################################################
|
||||
# Tcl/Tk Project manager 2.0
|
||||
@@ -43,6 +43,24 @@ package require fileutil
|
||||
# package require Thread
|
||||
package require fileutil::magic::filetype
|
||||
|
||||
# Определим установлен ли пакет Img для расширенной поддержки изображений
|
||||
proc PackagePresent {pkg} {
|
||||
# puts $pkg
|
||||
foreach item [package names] {
|
||||
# puts [string match -nocase Img $item]
|
||||
if {[string match -nocase Img $item] == 1} {
|
||||
puts "The $pkg package was found"
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if {[PackagePresent "Img"] eq "true"} {
|
||||
package require Img
|
||||
} else {
|
||||
puts "Img not present"
|
||||
}
|
||||
|
||||
# Устанавливаем текущий каталог
|
||||
set dir(root) [pwd]
|
||||
set dir(doc) [file join $dir(root) doc]
|
||||
|
||||
Reference in New Issue
Block a user