Skip to content

Latest commit

 

History

History
54 lines (43 loc) · 1.41 KB

README.md

File metadata and controls

54 lines (43 loc) · 1.41 KB

Composer Nexus Upload/Push

Simple PHP Script and Docker Image for uploading composer packages to a Nexus Respository.

Usage

Docker

docker run -it -v $(pwd):/workspace jbuncle/composer-nexus-upload:latest nexus-upload \
         --repository=https://example.nexus.repo.com/repository/composer-repo/ \
         --username=publisher-user \
         --password=$NEXUS_PASS \
         --version=$CI_COMMIT_TAG

Inline Bash

php <(curl -s https://raw.githubusercontent.com/jbuncle/composer-nexus-upload/master/nexus-upload.php) \
         --repository=https://example.nexus.repo.com/repository/composer-repo/ \
         --username=publisher-user \
         --password=$NEXUS_PASS \
         --version=$CI_COMMIT_TAG

CLI Arguments

Argument Description
repository The nexus composer repository URL
username The nexus user name
password The nexus user password
version The composer version

Files exclusion

To exclude files from the uploaded zip#

"extra": {
        "nexus-upload": {
            "ignore": [
                "node_modules/",
                "*.css.map",
                "*.ts",
                "*.zip",
                "webpack.config.js",
                "*.json",
                "*.less"
            ]
        }
    }