solo-doc 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -47,6 +47,15 @@ class OCPStrategy {
47
47
  this.name = 'OCP (Red Hat OpenShift)';
48
48
  }
49
49
  async execute(url, options) {
50
+ // Fix missing language code in URL (common mistake)
51
+ // https://docs.redhat.com/documentation/... -> https://docs.redhat.com/en/documentation/...
52
+ if (url.includes('docs.redhat.com/documentation/')) {
53
+ const fixedUrl = url.replace('docs.redhat.com/documentation/', 'docs.redhat.com/en/documentation/');
54
+ console.log(chalk_1.default.yellow(`[OCP] Detected missing language code. Auto-fixing URL:`));
55
+ console.log(chalk_1.default.gray(`Original: ${url}`));
56
+ console.log(chalk_1.default.cyan(`Fixed: ${fixedUrl}`));
57
+ url = fixedUrl;
58
+ }
50
59
  // Optimisation: Try to convert multi-page URL (/html/) to single-page URL (/html-single/)
51
60
  // Example: .../html/building_applications/index -> .../html-single/building_applications/index
52
61
  if (url.includes('/html/') && !url.includes('/html-single/')) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "solo-doc",
3
- "version": "0.3.1",
3
+ "version": "0.3.2",
4
4
  "main": "dist/bin/solo-doc.js",
5
5
  "bin": {
6
6
  "solo-doc": "dist/bin/solo-doc.js"