GithubHelp home page GithubHelp logo

Comments (5)

JustAnotherRandomUsername avatar JustAnotherRandomUsername commented on June 19, 2024

Hello vrreg!

(IMHO) You must not be rename UNIQUE path repository generated by scm-server!

  1. This feature (work logic) is allows to change name of your repository and guarantees that the path to files never lost.

  2. If you need any integrations, connectors or some custom query to scm-server please use scm-server api

example script:

#!/bin/bash

#scmadmin access token can be generated in gui
token="eyJhcGlLZXlJZCI6IjM2VGdXZDZJYUciLCJ1c2VyIjoic2NtPEQtaW4iLCJwYXNzcGhyYXNlIjoiaDhJZUNsSnBUZ0IKSDRTRzNzM2YifQ"

#text file to store info
vfile="finded_full.txt"

#clean old file
rm -rf $vfile

#create list uid+name by list uids
for repouid in $(ls -1 /data/repositories)
do
v=$(curl -s -X 'GET' "http://127.0.0.1/api/v2/legacy/repository/$repouid" -H "accept: application/json" -H "Cookie: X-Bearer-Token=$token")
reponame=`echo $v | awk -F'"' '{print $4}'`
echo $repouid $reponame >> $vfile
done
echo "data saved to path: $vfile"

Best regards

from scm-manager.

vrreg avatar vrreg commented on June 19, 2024

Thanks for your comment. My comment above was an example. One can leave the UNIQUE ID but simply re-name the directory and update the repository-paths.xml

ie.
<?xml version="1.0" encoding="UTF-8"?> <repositories creation-time="1691612257430" last-modified="1691620475246"> <repository id="4OTmTj7Ma7">repositories/MYCOOLREPOSITORY</repository> </repositories>

from scm-manager.

eheimbuch avatar eheimbuch commented on June 19, 2024

Hey @vrreg,

would it be sufficient if we create another directory containing sym-links to all repositories? Each sym-link could be named as your actual repository name. We have already discussed this "feature" internally some time ago.

Your proposal could work but we had to verify that none of our many plugins breaks with this changes. Also, this will most likely bring complicated edge cases like path conflicts and validations.

from scm-manager.

vrreg avatar vrreg commented on June 19, 2024

Hi @eheimbuch ,

Thanks for considering my suggestion.

I would say this might become convoluted in the long run and a challenge to maintain.

Right now to backup and SCM setup, one could copy the .xml configuration files (in addition to saving the repository data) . With a folder of symlinks, that's one more thing that must be properly saved and backing up symlinks can be tricky.

from scm-manager.

pfeuffer avatar pfeuffer commented on June 19, 2024

Hey @vrreg ,

sorry for the late follow-up. You can install the custom storage plugin (maybe you have found it already in the meantime). Here you can see and modify the paths for all repositories and also configure a custom path pattern for new repositories. This should fit your needs. If not, please let us know.

Regards
RenΓ©

from scm-manager.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.