Browse Source

Add function

pull/2/head
Luke Childs 9 years ago
parent
commit
7891de98b8
  1. 7
      src/htconvert.js

7
src/htconvert.js

@ -0,0 +1,7 @@
const redirectRegex = /(?:Redirect\s*(\d*)\s*)(\S*)(?:\s*)(\S*)/g;
const nginxPattern =
`location $2 {
return $1 $3;
}`;
export default htaccessRules => htaccessRules.replace(redirectRegex, nginxPattern);
Loading…
Cancel
Save