https://github.com/conda/conda-prefix-replacement

CPR resuscitates packages in new locations

https://github.com/conda/conda-prefix-replacement

Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (7.7%) to scientific vocabulary
Last synced: 10 months ago · JSON representation

Repository

CPR resuscitates packages in new locations

Basic Info
  • Host: GitHub
  • Owner: conda
  • License: bsd-3-clause
  • Language: Python
  • Default Branch: main
  • Size: 231 KB
Statistics
  • Stars: 15
  • Watchers: 11
  • Forks: 10
  • Open Issues: 1
  • Releases: 2
Created over 7 years ago · Last pushed over 1 year ago
Metadata Files
Readme Changelog License Code of conduct Authors

README.md

conda-prefix-replacement

CPR resuscitates packages in new locations. It's a library for detecting files that have the absolute path of the build-time install prefix baked into them, and also for replacing those baked-in prefixes with new values when files are moved.

Both text and binary files are processed. For the latter the total length of the binary must not change, hence the new prefix is overwritten in place and must be no longer than the old one. Any freed up space is filled with the "end of string" character. To ensure that the initially used installation path is long enough it is chosen to be 255 characters long.

``` usage: cpr [-h] [-V] {detect,d,replace,r,rehome} ...

Tool for replacing hard-coded prefixes in text and binary files

optional arguments: -h, --help show this help message and exit -V, --version Show the conda-prefix-replacement version number and exit.

subcommands: {detect,d,replace,r,rehome} detect (d) detect hard-coded prefixes in files replace (r) replace hard-coded prefixes in files with new value rehome fix a moved installation by changing embedded paths to match the new location ```

Most people probably just want rehome, which combines the detect and replace functions. For example, say you copy your Anaconda installation from /Anaconda3 to ~/anaconda3. You can fix the embedded paths by running:

cpr rehome ~/anaconda3

That finds your old prefix by looking in some files that are known to record the prefix in a readily parseable way. If that fails, you can still fix things as long as you know what the original path was:

cpr rehome ~/anaconda3 --old-prefix /Anaconda3

The detect and replace commands are more for conda/conda-build usage. Conda-build detects files that have the prefix at build time, so that those prefixes can be replaced by conda at install time.

Owner

  • Name: conda
  • Login: conda
  • Kind: organization

conda is system-level, binary package and environment manager running on all major operating systems and platforms.

GitHub Events

Total
  • Issues event: 2
  • Watch event: 3
  • Issue comment event: 3
  • Push event: 7
  • Pull request review event: 8
  • Pull request event: 19
  • Fork event: 1
Last Year
  • Issues event: 2
  • Watch event: 3
  • Issue comment event: 3
  • Push event: 7
  • Pull request review event: 8
  • Pull request event: 19
  • Fork event: 1

Committers

Last synced: 11 months ago

All Time
  • Total Commits: 64
  • Total Committers: 6
  • Avg Commits per committer: 10.667
  • Development Distribution Score (DDS): 0.344
Past Year
  • Commits: 14
  • Committers: 2
  • Avg Commits per committer: 7.0
  • Development Distribution Score (DDS): 0.071
Top Committers
Name Email Commits
conda-bot 1****t 42
Mike Sarahan m****n@g****m 16
conda-bot a****t@a****m 3
Oleg Alexandrov o****v@g****m 1
Ken Odegard k****d@a****m 1
Alexander Dunkel 1****s 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 10 months ago

All Time
  • Total issues: 1
  • Total pull requests: 59
  • Average time to close issues: N/A
  • Average time to close pull requests: 11 days
  • Total issue authors: 1
  • Total pull request authors: 5
  • Average comments per issue: 0.0
  • Average comments per pull request: 0.19
  • Merged pull requests: 53
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 1
  • Pull requests: 20
  • Average time to close issues: N/A
  • Average time to close pull requests: 14 days
  • Issue authors: 1
  • Pull request authors: 2
  • Average comments per issue: 0.0
  • Average comments per pull request: 0.2
  • Merged pull requests: 15
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • msarahan (1)
Pull Request Authors
  • conda-bot (64)
  • msarahan (3)
  • Sieboldianus (2)
  • kenodegard (1)
  • oleg-alexandrov (1)
Top Labels
Issue Labels
type::feature (1)
Pull Request Labels
cla-signed (61) locked (34)

Packages

  • Total packages: 2
  • Total downloads: unknown
  • Total dependent packages: 0
    (may contain duplicates)
  • Total dependent repositories: 0
    (may contain duplicates)
  • Total versions: 2
conda-forge.org: conda-prefix-replacement
  • Versions: 1
  • Dependent Packages: 0
  • Dependent Repositories: 0
Rankings
Dependent repos count: 34.0%
Forks count: 44.7%
Average: 45.8%
Dependent packages count: 51.2%
Stargazers count: 53.5%
Last synced: 10 months ago
anaconda.org: conda-prefix-replacement
  • Versions: 1
  • Dependent Packages: 0
  • Dependent Repositories: 0
Rankings
Dependent packages count: 39.8%
Average: 49.5%
Forks count: 49.7%
Stargazers count: 50.8%
Dependent repos count: 57.7%
Last synced: 10 months ago

Dependencies

.github/workflows/cla.yml actions
  • conda/actions/check-cla v22.9.0 composite
.github/workflows/issues.yml actions
  • actions-ecosystem/action-add-labels v1.1.0 composite
  • actions-ecosystem/action-remove-labels v1.3.0 composite
.github/workflows/labels.yml actions
  • EndBug/label-sync v2.3.0 composite
  • actions/checkout v3 composite
  • andstor/file-existence-action v1.0.1 composite
.github/workflows/lock.yml actions
  • dessant/lock-threads v2 composite
.github/workflows/project.yml actions
  • actions/add-to-project v0.3.0 composite
.github/workflows/stale.yml actions
  • actions/stale v4 composite
  • conda/actions/read-yaml v22.9.0 composite
setup.py pypi
.github/workflows/update.yml actions
  • actions/checkout 692973e3d937129bcbf40652eb9f2f61becf3332 composite
  • conda/actions/combine-durations 15f883f14f4232f83658e3609c3316d58905138f composite
  • conda/actions/template-files 15f883f14f4232f83658e3609c3316d58905138f composite
  • peter-evans/create-or-update-comment 71345be0265236311c031f5c7866368bd1eff043 composite
  • peter-evans/create-pull-request c5a7806660adbe173f04e3e038b0ccdcd758773c composite