简体   繁体   中英

Jenkins - git checkout deletes files

I have the following Jenkins pipeline:

node {
    dir('/my/dir'){
        stage 'checkout'
        git url: 'https://github.com/my/project.git'
    }
}

There were a few files in /my/dir which were deleted after this pipeline completed.

Is this due to dir or git ?

这是由于git步骤所致,因为您告诉步骤将存储库克隆到cwd中,该文件为/my/dir/ ,其中git会清理目录。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM