| # GENERATED BY: test/dependency_services/dependency_services_test.dart |
| |
| $ cat pubspec.yaml |
| {"name":"myapp","dependencies":{"foo":{"git":{"url":"../foo.git"}},"bar":{"git":{"url":"../bar.git"},"version":"^1.0.0"}},"environment":{"sdk":"^3.0.2"}} |
| $ cat pubspec.lock |
| # Generated by pub |
| # See https://dart.dev/tools/pub/glossary#lockfile |
| packages: |
| bar: |
| dependency: "direct main" |
| description: |
| path: "." |
| ref: HEAD |
| resolved-ref: "1ea665d6de007c60308949db4c6ae8049c2395f0" |
| url: "../bar.git" |
| source: git |
| version: "1.0.0" |
| foo: |
| dependency: "direct main" |
| description: |
| path: "." |
| ref: HEAD |
| resolved-ref: "9e8b8ad5091bec2c4724b1e0c8ff9d6e32a7eaa4" |
| url: "../foo.git" |
| source: git |
| version: "1.0.0" |
| sdks: |
| dart: ">=3.0.2 <4.0.0" |
| -------------------------------- END OF OUTPUT --------------------------------- |
| |
| ## Section list |
| $ echo '' | dependency_services list |
| { |
| "dependencies": [ |
| { |
| "name": "bar", |
| "version": "1ea665d6de007c60308949db4c6ae8049c2395f0", |
| "kind": "direct", |
| "constraint": "^1.0.0", |
| "source": { |
| "type": "git", |
| "description": { |
| "url": "../bar.git", |
| "ref": "HEAD", |
| "resolved-ref": "1ea665d6de007c60308949db4c6ae8049c2395f0", |
| "path": "." |
| } |
| } |
| }, |
| { |
| "name": "foo", |
| "version": "9e8b8ad5091bec2c4724b1e0c8ff9d6e32a7eaa4", |
| "kind": "direct", |
| "constraint": "any", |
| "source": { |
| "type": "git", |
| "description": { |
| "url": "../foo.git", |
| "ref": "HEAD", |
| "resolved-ref": "9e8b8ad5091bec2c4724b1e0c8ff9d6e32a7eaa4", |
| "path": "." |
| } |
| } |
| } |
| ] |
| } |
| |
| -------------------------------- END OF OUTPUT --------------------------------- |
| |
| ## Section report |
| $ echo '' | dependency_services report |
| { |
| "dependencies": [ |
| { |
| "name": "bar", |
| "version": "1ea665d6de007c60308949db4c6ae8049c2395f0", |
| "kind": "direct", |
| "source": { |
| "type": "git", |
| "description": { |
| "url": "../bar.git", |
| "ref": "HEAD", |
| "resolved-ref": "1ea665d6de007c60308949db4c6ae8049c2395f0", |
| "path": "." |
| } |
| }, |
| "latest": "6385a9b18caf6b92622d4ecef32356aeaab35ff7", |
| "constraint": "^1.0.0", |
| "compatible": [], |
| "singleBreaking": [ |
| { |
| "name": "bar", |
| "version": "6385a9b18caf6b92622d4ecef32356aeaab35ff7", |
| "kind": "direct", |
| "source": { |
| "type": "git", |
| "description": { |
| "url": "../bar.git", |
| "ref": "HEAD", |
| "resolved-ref": "6385a9b18caf6b92622d4ecef32356aeaab35ff7", |
| "path": "." |
| } |
| }, |
| "constraintBumped": "^2.0.0", |
| "constraintWidened": ">=1.0.0 <3.0.0", |
| "constraintBumpedIfNeeded": "^2.0.0", |
| "previousVersion": "1ea665d6de007c60308949db4c6ae8049c2395f0", |
| "previousConstraint": "^1.0.0", |
| "previousSource": { |
| "type": "git", |
| "description": { |
| "url": "../bar.git", |
| "ref": "HEAD", |
| "resolved-ref": "1ea665d6de007c60308949db4c6ae8049c2395f0", |
| "path": "." |
| } |
| } |
| } |
| ], |
| "multiBreaking": [ |
| { |
| "name": "bar", |
| "version": "6385a9b18caf6b92622d4ecef32356aeaab35ff7", |
| "kind": "direct", |
| "source": { |
| "type": "git", |
| "description": { |
| "url": "../bar.git", |
| "ref": "HEAD", |
| "resolved-ref": "6385a9b18caf6b92622d4ecef32356aeaab35ff7", |
| "path": "." |
| } |
| }, |
| "constraintBumped": "^2.0.0", |
| "constraintWidened": ">=1.0.0 <3.0.0", |
| "constraintBumpedIfNeeded": "^2.0.0", |
| "previousVersion": "1ea665d6de007c60308949db4c6ae8049c2395f0", |
| "previousConstraint": "^1.0.0", |
| "previousSource": { |
| "type": "git", |
| "description": { |
| "url": "../bar.git", |
| "ref": "HEAD", |
| "resolved-ref": "1ea665d6de007c60308949db4c6ae8049c2395f0", |
| "path": "." |
| } |
| } |
| } |
| ] |
| }, |
| { |
| "name": "foo", |
| "version": "9e8b8ad5091bec2c4724b1e0c8ff9d6e32a7eaa4", |
| "kind": "direct", |
| "source": { |
| "type": "git", |
| "description": { |
| "url": "../foo.git", |
| "ref": "HEAD", |
| "resolved-ref": "9e8b8ad5091bec2c4724b1e0c8ff9d6e32a7eaa4", |
| "path": "." |
| } |
| }, |
| "latest": "385bb2860e7ebf9519993b2548d6cab74a6008ef", |
| "constraint": "any", |
| "compatible": [], |
| "singleBreaking": [], |
| "multiBreaking": [ |
| { |
| "name": "foo", |
| "version": "385bb2860e7ebf9519993b2548d6cab74a6008ef", |
| "kind": "direct", |
| "source": { |
| "type": "git", |
| "description": { |
| "url": "../foo.git", |
| "ref": "HEAD", |
| "resolved-ref": "385bb2860e7ebf9519993b2548d6cab74a6008ef", |
| "path": "." |
| } |
| }, |
| "constraintBumped": "2.0.0", |
| "constraintWidened": "any", |
| "constraintBumpedIfNeeded": "any", |
| "previousVersion": "9e8b8ad5091bec2c4724b1e0c8ff9d6e32a7eaa4", |
| "previousConstraint": "any", |
| "previousSource": { |
| "type": "git", |
| "description": { |
| "url": "../foo.git", |
| "ref": "HEAD", |
| "resolved-ref": "9e8b8ad5091bec2c4724b1e0c8ff9d6e32a7eaa4", |
| "path": "." |
| } |
| } |
| } |
| ] |
| } |
| ] |
| } |
| |
| -------------------------------- END OF OUTPUT --------------------------------- |
| |
| ## Section apply |
| $ echo '{"dependencyChanges":[{"name":"foo","version":"385bb2860e7ebf9519993b2548d6cab74a6008ef"}]}' | dependency_services apply |
| {"dependencies":[]} |
| |
| -------------------------------- END OF OUTPUT --------------------------------- |
| |
| $ cat pubspec.yaml |
| {"name":"myapp","dependencies":{"foo":{"git":{"url":"../foo.git"}},"bar":{"git":{"url":"../bar.git"},"version":"^1.0.0"}},"environment":{"sdk":"^3.0.2"}} |
| $ cat pubspec.lock |
| # Generated by pub |
| # See https://dart.dev/tools/pub/glossary#lockfile |
| packages: |
| bar: |
| dependency: "direct main" |
| description: |
| path: "." |
| ref: HEAD |
| resolved-ref: "1ea665d6de007c60308949db4c6ae8049c2395f0" |
| url: "../bar.git" |
| source: git |
| version: "1.0.0" |
| foo: |
| dependency: "direct main" |
| description: |
| path: "." |
| ref: HEAD |
| resolved-ref: "385bb2860e7ebf9519993b2548d6cab74a6008ef" |
| url: "../foo.git" |
| source: git |
| version: "2.0.0" |
| sdks: |
| dart: ">=3.0.2 <4.0.0" |