apm_ignore_file_p (public)

 apm_ignore_file_p [ -data_model_files ] path

Defined in packages/acs-bootstrap-installer/tcl/30-apm-load-procs.tcl

Return 1 if $path should, in general, be ignored for package operations. Currently, a file is ignored if it is a backup file or a CVS directory.

Switches:
-data_model_files (optional, boolean)
Parameters:
path (required)

Partial Call Graph (max 5 caller/called nodes):
%3 test_files__page_contracts files__page_contracts (test acs-tcl) apm_ignore_file_p apm_ignore_file_p test_files__page_contracts->apm_ignore_file_p ad_file ad_file (public) apm_ignore_file_p->ad_file apm_backup_file_p apm_backup_file_p (private) apm_ignore_file_p->apm_backup_file_p apm_include_data_model_file_p apm_include_data_model_file_p (private) apm_include_data_model_file_p->apm_ignore_file_p apm_include_file_p apm_include_file_p (private) apm_include_file_p->apm_ignore_file_p apm_scan_packages apm_scan_packages (public) apm_scan_packages->apm_ignore_file_p

Testcases:
files__page_contracts
Source code:
    if {[ad_file isdirectory $path]} {
        #
        # ignored directories
        #
        set parts [ad_file split $path]
        if {[lindex $parts end] eq "resources" && [lindex $parts end-1] eq "www"} {
            return 1
        }

        set dir_list {CVS .git catalog}
        if {!$data_model_files_p} {
            lappend dir_list "upgrade"
        }

        if {[lindex $parts end] in $dir_list} {
            return 1
        }
    }
    #
    # ignored extensions
    #
    set extension_list {.html .gif .png .jpg .ico .pdf .js .css .xsl .tgz .zip .gz .java}
    if {!$data_model_files_p} {
        lappend extension_list ".sql"
    }
    if {[ad_file extension $path] in $extension_list} {
        return 1
    }
    
    if { [string index $path 0] eq "~"} {
        set path ./$path
    }
    if { [apm_backup_file_p [ad_file tail $path]] } {
        return 1
    }

    return 0
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: