OSDN Git Service

[add] : カーネル設定
authorhayao <shun819.mail@gmail.com>
Wed, 2 Sep 2020 14:31:27 +0000 (23:31 +0900)
committerhayao <shun819.mail@gmail.com>
Wed, 2 Sep 2020 14:31:27 +0000 (23:31 +0900)
alteriso-options-generator/index.php
alteriso-options-generator/kernellist.js [new file with mode: 0644]

index 4830c9f..1a72881 100644 (file)
                     </div>
                     <!-- 圧縮設定 ここまで-->
 
+                    <!-- カーネル ここから-->
+                    <div class="box_child">
+                        <p class="option_title"><h3>カーネル</h3></p>
+                        <p class="option_description">使用するカーネルを設定します</p>
+                        <p class="option_form">
+                            <select name="kernel" id="kernel">
+                                <option value="core">linux</option>
+                                <option value="lts">linux-lts</option>
+                                <option value="zen">linux-zen</option>
+                                <script>
+
+                                </script>
+                                
+                            </select>
+                        </p>
+
+                    </div>
+                    <!-- カーネル ここまで-->
+
                     <!-- ユーザー ここから-->
                     <div class="box_child">
                         <p class="option_title"><h3>ライブ環境ユーザー名</h3></p>
diff --git a/alteriso-options-generator/kernellist.js b/alteriso-options-generator/kernellist.js
new file mode 100644 (file)
index 0000000..2185c47
--- /dev/null
@@ -0,0 +1,49 @@
+//var _Architecture = document.getElementById("architecture").value
+//if (_Architecture = "x86_64") {
+//    var _option = document.createElement('option');
+//    _option.text = "linux-lqx";
+//    _option.value = "lqx";
+//    document.getElementById("kernel").appendChild(_option);
+//}
+
+// 参考
+// https://techacademy.jp/magazine/27133
+// https://techacademy.jp/magazine/22315
+// 
+
+function createKernelList(_kernel) {
+    var _option = document.createElement('option');
+    if ( _kernel == "core"){
+        _option.text = "linux";
+        _option.value = "core";
+    } else {
+        _option.text = "linux-" + _kernel;
+        _option.value = _kernel;
+    }
+    document.getElementById("kernel").appendChild(_option);
+}
+
+function createListAny() {
+    createKernelList("core");
+    createKernelList("lts");
+    createKernelList("zen");
+}
+
+function createListx86_64() {
+    createKernelList("hardened");
+    createKernelList("lqx");
+    createKernelList("ck");
+    createKernelList("rt");
+    createKernelList("rt-lts");
+    createKernelList("xanmod");
+    createKernelList("xanmod-lts");
+    createKernelList("zen-letsnote");
+}
+
+function kernelMain() {
+    var _Architecture = document.getElementById("architecture").value;
+    createListAny();
+    if (_Architecture = "x86_64") {
+        createListx86_64();
+    }
+}
\ No newline at end of file