How to scrape/attain a url from tfs source control and append it to a markdown file?

给你一囗甜甜゛ 提交于 2020-01-06 05:47:26

问题


I'm in the process of setting up a prototype for documentation generation using source controlled files on tfs via docfx.

I'd like to be able to create a link on each article such that upon clicking it, it directs me to the file on tfs.

For example, if I have a file called index.md and the url for it is

http://tfs:8080/tfs/{collection}/{directory}/{restofthepath}Findex.md&_a=contents

I'd like to be able to somehow append that url as a link in index.md. Is there a way to do this?

In essence I'm trying to figure out a way to automatically copy/paste the tfs url path for every article/md file to the file itself so that I can later generate an edit link.

At the moment, I would need to go through every file and copy paste the tfs url into an href.

A little clarification:

  • index.md stored in tfs under some link, lets call it tfs:8080:blabla
  • I want to store that link in index.md somehow (naturally, I can simply copy paste tfs:8080:blabla into index.md and now index.md has a link pointing to where it's sourced) - any way to make an automated process for this?

来源:https://stackoverflow.com/questions/56890539/how-to-scrape-attain-a-url-from-tfs-source-control-and-append-it-to-a-markdown-f

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!