mirror of
https://github.com/videojs/video.js.git
synced 2025-01-15 10:39:58 +02:00
21 lines
492 B
JavaScript
21 lines
492 B
JavaScript
var replace = require("replace");
|
|
var path = require('path')
|
|
var apiPath = path.join(__dirname, '..', 'docs', 'api');
|
|
|
|
var replacements = [
|
|
{find: /\/docs\/guides\/(.+)\.md/g, replace: 'tutorial-$1.html'},
|
|
{find: /tutorial-tech.html/g, replace: 'tutorial-tech_.html'},
|
|
{find: /\/docs\/guides\//g, replace: '#'}
|
|
];
|
|
|
|
|
|
replacements.forEach(function(obj) {
|
|
replace({
|
|
regex: obj.find,
|
|
replacement: obj.replace,
|
|
paths: [apiPath],
|
|
recursive: true,
|
|
silent: true
|
|
});
|
|
});
|