mirror of
https://gitee.com/johng/gf
synced 2026-06-07 18:26:02 +08:00
Compare commits
4980 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| fb89f8bdf8 | |||
| cae8ce3b51 | |||
| 9a91bd203b | |||
| 72733e0bad | |||
| d44e082ff5 | |||
| 078c1bc7f9 | |||
| 94623a19d1 | |||
| cb7cfa58ab | |||
| 1878202625 | |||
| bb71ccfd4c | |||
| f67b2dca26 | |||
| 68b02218d7 | |||
| 766579d868 | |||
| 030cd84836 | |||
| 6314cd4c89 | |||
| 0588009c40 | |||
| 6204c132c7 | |||
| a4b80e8680 | |||
| 0e1cb15dc0 | |||
| 612e545ae2 | |||
| bbdd442954 | |||
| 6686bd65a2 | |||
| 319a812934 | |||
| 307c6ec307 | |||
| bac637570d | |||
| c8a11f7f6e | |||
| e0c032d1b1 | |||
| 063264ebff | |||
| 02abc515a3 | |||
| be7851c664 | |||
| dc08920a7f | |||
| 1ab0b18115 | |||
| ebd78fb533 | |||
| 841003eeb3 | |||
| 1739d4dfb2 | |||
| 46cc4cef9e | |||
| 90331d85bf | |||
| 98fd2a1973 | |||
| d5633ebad7 | |||
| 58d6410291 | |||
| 54087de518 | |||
| fc39fffe9c | |||
| 6a3ea897a8 | |||
| 91f9864b25 | |||
| 8c8c7c8c71 | |||
| 73211707fb | |||
| 609f44c5fe | |||
| 0a82036da5 | |||
| b4053ed32e | |||
| 110e3fbf16 | |||
| 095c69c424 | |||
| cee6f499fc | |||
| 73560cfe31 | |||
| 9a7df9944c | |||
| dd02af1b2f | |||
| 626fc629ef | |||
| 2d05fb426f | |||
| bf2997e9cc | |||
| 82d4d77e56 | |||
| 4f43b40a18 | |||
| f3f2cb3c57 | |||
| 102c3b6cb0 | |||
| 5e677a1e05 | |||
| 75f89f19ba | |||
| afe6bebde7 | |||
| 2af2342d67 | |||
| c9641ea115 | |||
| d8a173d9f0 | |||
| 5d1712b4ab | |||
| a4f98c2490 | |||
| d1cd30c9b4 | |||
| 5979261584 | |||
| df463d75bc | |||
| de9d3c2b3c | |||
| ce3599a672 | |||
| cd6fd247e2 | |||
| be91c4889e | |||
| 6219da7a76 | |||
| c600f3aae8 | |||
| 9dd43cd331 | |||
| 3e73e2d2cc | |||
| 1ed4e0267a | |||
| 3120a8bc22 | |||
| 13524a36bc | |||
| cb26931378 | |||
| 40f4d9f8ec | |||
| caea7ea4b8 | |||
| a6485d53af | |||
| db9f47d942 | |||
| c5778127b1 | |||
| 8f826edc43 | |||
| d148e0ea62 | |||
| d091547212 | |||
| 6334ee1958 | |||
| 24939eb0d6 | |||
| dd62b18877 | |||
| cb4681ce3e | |||
| 7daf916032 | |||
| c82da1e57c | |||
| 90564f9fb0 | |||
| 4d6c7e3d3a | |||
| 18e77de02f | |||
| bf6238e178 | |||
| 887a776441 | |||
| 7274a7399a | |||
| b59824e9dc | |||
| 5cbe421aaa | |||
| 852c3dda62 | |||
| d8b857f930 | |||
| d353bf0fbc | |||
| baf30a0e99 | |||
| 6e0ba551f9 | |||
| 1650aab340 | |||
| bb9133ab9d | |||
| 48845c3473 | |||
| ea956189bf | |||
| 3912d97811 | |||
| 50fb349bc9 | |||
| 777d7aabb5 | |||
| 5a67aac85d | |||
| 132a5ab9a3 | |||
| 8575f01273 | |||
| ac75026716 | |||
| 485a9637cc | |||
| b57b49ecca | |||
| cdead46c79 | |||
| a4883e6e3d | |||
| fe8ba5e35f | |||
| 54b7c249fd | |||
| 99d69857fa | |||
| 1b26013a66 | |||
| 6c2155bd26 | |||
| 9018a3d4ac | |||
| 362d4202c4 | |||
| a85b221d32 | |||
| cb8594eb80 | |||
| ac88e640d1 | |||
| 2d307c5dd1 | |||
| 54453c8e8f | |||
| 072b962b81 | |||
| a80f58b7f6 | |||
| 1e3aa5f080 | |||
| fde47e8981 | |||
| c02148cd6b | |||
| 1d4e684949 | |||
| 8ff0de88b8 | |||
| ac3efe5a00 | |||
| 2744fe2212 | |||
| 1682cc98bb | |||
| 2742c98c06 | |||
| 4226a23a39 | |||
| b8e414e125 | |||
| 08c34b5ed7 | |||
| 416f314390 | |||
| 98f0c36a1d | |||
| 2b7b4c8581 | |||
| b8844f3d40 | |||
| 3e2176d799 | |||
| 2f9225057f | |||
| 7b373446dc | |||
| 0f6d47c7a8 | |||
| f24729206b | |||
| 7e9715ab1d | |||
| f565a347c4 | |||
| f172e61585 | |||
| 22d873f6bd | |||
| b60b04e27a | |||
| d2bc5d812b | |||
| 0648fd688e | |||
| d0cfcce85b | |||
| 2518d490c3 | |||
| edc96a8c16 | |||
| 22427a08ad | |||
| 41a5484620 | |||
| 325ee45a55 | |||
| 627aa5d27f | |||
| 47db44843e | |||
| a39498f74f | |||
| 80b866e11c | |||
| 2a77d3203e | |||
| 3c451bef82 | |||
| 5073f25691 | |||
| 40e97f1325 | |||
| 502d158bc0 | |||
| f08897a114 | |||
| b6181e4bde | |||
| f8cdeae2d7 | |||
| bea060af4c | |||
| 94cc233325 | |||
| 71743e6903 | |||
| f9ec3b19f7 | |||
| ee24da4e72 | |||
| 26f20787ba | |||
| 1371b3bad5 | |||
| 1da73451b9 | |||
| 94b623e126 | |||
| 4262aa254d | |||
| 8cff64915b | |||
| bec98e8de0 | |||
| a6dbf4b7eb | |||
| 0c2f60468b | |||
| 656ae070da | |||
| 2d5fcd73cb | |||
| 82043856f4 | |||
| 7ffdff37e4 | |||
| 24083b865d | |||
| 8cb64c9f88 | |||
| 5fa656d1cc | |||
| 09ec90746a | |||
| c0d1e44526 | |||
| b323862b4c | |||
| 3d9cdb8997 | |||
| 7180d895ea | |||
| afb1595fbe | |||
| 6637add9ca | |||
| bc862cf97b | |||
| 9033ca087b | |||
| b985fd978c | |||
| 88c4471500 | |||
| b73e2047db | |||
| 1534abdb05 | |||
| fee38b4531 | |||
| 69e3362d0d | |||
| 9a61a6970f | |||
| abf77fac50 | |||
| 07696fc779 | |||
| bc1e1019c5 | |||
| bb696bb281 | |||
| 029f324c5c | |||
| f8331bad6e | |||
| bcda48bf82 | |||
| a8a055f122 | |||
| dfe088f5cd | |||
| f4074cd815 | |||
| 4a65e7a629 | |||
| ac653d3dee | |||
| 2d3ab4f9fb | |||
| bda42d18ee | |||
| 63cb3285f8 | |||
| 2fa03556ef | |||
| 01593ad8b6 | |||
| 42d8845d35 | |||
| 1ef1c442d3 | |||
| 7d3b055d3e | |||
| a3b3c656d9 | |||
| 0eb229a887 | |||
| 20b1987828 | |||
| e12768207e | |||
| f9c7eae23b | |||
| 1f8845291a | |||
| 6bd15b0796 | |||
| 99f0fb14a1 | |||
| e0f734851e | |||
| 3f24b4da2e | |||
| fc9093a1aa | |||
| f66e09717c | |||
| 80f57d1c24 | |||
| 9ce2409659 | |||
| 6ea1526b75 | |||
| 89e5285d95 | |||
| e6bee78be4 | |||
| 96e833db6e | |||
| 3a19ee9268 | |||
| 594979c5af | |||
| 4c2a78b7bf | |||
| 817ac36ce2 | |||
| 2c1fcec88c | |||
| 92eab81926 | |||
| a5c8b966e2 | |||
| 233295be07 | |||
| 67a9db9e3e | |||
| e7fdf82dd8 | |||
| f79aef6669 | |||
| 0c2d5cac19 | |||
| 5104f01b69 | |||
| a09454accf | |||
| ac53170884 | |||
| e3e82c7351 | |||
| ced4b57991 | |||
| 5af342adc3 | |||
| 5c45d3533f | |||
| d748fb6564 | |||
| 00e2f6b5dc | |||
| b7c74c9a35 | |||
| 69969b1723 | |||
| 38bffc77e2 | |||
| 2e788be1d3 | |||
| 13bc192e36 | |||
| bae78fbf5b | |||
| 80e73da416 | |||
| 5e47590165 | |||
| 3cffa4d5d6 | |||
| e18331aa2c | |||
| b0b84a3937 | |||
| 2066aa4803 | |||
| b8142bf1fc | |||
| ba968949f7 | |||
| c9b0237fc7 | |||
| 4ad061faff | |||
| 5fa33411fc | |||
| c0f2ef7348 | |||
| 77cb7fb412 | |||
| 7cd672d22c | |||
| e2cafa35e0 | |||
| 532e665841 | |||
| 2d0cd7b770 | |||
| 2c916f8222 | |||
| 42eae41599 | |||
| 5aa7504bb2 | |||
| ec6e091882 | |||
| c1850d4ab5 | |||
| 9923975b1c | |||
| e572ed01b3 | |||
| 16d73b5bdf | |||
| 5521d768ff | |||
| 81aed06643 | |||
| 455830b842 | |||
| e56371e7c9 | |||
| eb8024913d | |||
| ee3eb8d48c | |||
| 15f94975db | |||
| 3797d0eee4 | |||
| e9ce1bde87 | |||
| 9c8b21af7b | |||
| 90851881cc | |||
| 3090fe7f4e | |||
| 0d1aed0741 | |||
| 910703ec3a | |||
| ec6c537def | |||
| bcfcda793c | |||
| 138dea0f3a | |||
| 3d4904eb3d | |||
| 955a76cf35 | |||
| ffa6081471 | |||
| 6baf4338b0 | |||
| 8c6db247b2 | |||
| fff2f8a24c | |||
| 475e8bbae0 | |||
| 070efecc6e | |||
| a63af5d5f8 | |||
| bd2e8408e8 | |||
| 6c6fd7902a | |||
| 1b7b536d6c | |||
| 9cc1cf1b53 | |||
| 76948d93d6 | |||
| 5ba165a3c0 | |||
| f4db846633 | |||
| e7cc2c3d9c | |||
| 01cd0103e4 | |||
| d1872f17f7 | |||
| e4c4fb591e | |||
| 656668f444 | |||
| 555bb3fa6b | |||
| e179e1d4fe | |||
| 7dd38a1700 | |||
| b1d875a31f | |||
| c18339b1a9 | |||
| 5288b70567 | |||
| 4b5f637651 | |||
| e3e5c89ba7 | |||
| 4d29939f87 | |||
| ae3ae8b177 | |||
| 7a6889817f | |||
| a72a9ff13e | |||
| 91884e7c93 | |||
| 7cbc9e8533 | |||
| 2301de6e8c | |||
| 183395f0a0 | |||
| d4fa2c82bf | |||
| 459c8ce84e | |||
| 38622f966f | |||
| 499f755d3a | |||
| 3f1439ac4c | |||
| 0ca2ed5979 | |||
| ee5284a1b2 | |||
| 8e7f1180c4 | |||
| 3abb9477c4 | |||
| ab3fbddfc7 | |||
| 55b92151f4 | |||
| 9589384b36 | |||
| cf742233e8 | |||
| 1c97b7a982 | |||
| ea09457d84 | |||
| 66ee52c96a | |||
| f45f64897a | |||
| 8708dc7940 | |||
| 79451e4624 | |||
| a716c6bfab | |||
| 5aa321dbde | |||
| 3f2b1cb329 | |||
| ab2c3b02ac | |||
| 76783fd72b | |||
| a1ce97ec9b | |||
| c13004e230 | |||
| 9af8393758 | |||
| e15b543a5b | |||
| 8a1c97f518 | |||
| d8e3e9d713 | |||
| 777c2e7117 | |||
| c4327f62e7 | |||
| fd33dcb97b | |||
| d8b06d056e | |||
| e186eab1a5 | |||
| 6a99931798 | |||
| 4ee5bf5c45 | |||
| e4669387b5 | |||
| 0e471eab38 | |||
| 3d63ebfe81 | |||
| 9b318bb57f | |||
| 6b3fb607cf | |||
| bb9a3b83eb | |||
| baea1c7a7a | |||
| 1b4ebc0812 | |||
| 803cb5a0bc | |||
| 448df14860 | |||
| 467a5c1093 | |||
| 26d2a98fb1 | |||
| 6e5ce98d23 | |||
| a6c361dcf7 | |||
| dc8bb809a8 | |||
| 9143b26182 | |||
| cd2d51ea30 | |||
| 144ad5f263 | |||
| 4fdafa4517 | |||
| ba322ba0ac | |||
| 559ae0e77e | |||
| 3e54839aa8 | |||
| 2565bb3d07 | |||
| 54423b6d84 | |||
| c3cfc01cf6 | |||
| 31a6ae2a19 | |||
| b11caba5b0 | |||
| 8824b8b0fe | |||
| f8272bc5f4 | |||
| e8a2629b19 | |||
| dba6c08548 | |||
| 7d464d4de2 | |||
| 4abb32e11b | |||
| 74d0945fa1 | |||
| ffbe9a7197 | |||
| fba878f47a | |||
| 88f188d0f9 | |||
| 2ccbb02c71 | |||
| 01408f1a87 | |||
| dea0ffcfb3 | |||
| d5825ab51c | |||
| 753965b9a9 | |||
| ee211dbdac | |||
| 4d916ae73e | |||
| 59a775aad4 | |||
| e3a00d7f56 | |||
| bd8d046b83 | |||
| 57583a98bc | |||
| f8175e7113 | |||
| 6b84a37794 | |||
| 457f7abcf5 | |||
| 9e9e42b45c | |||
| 8f4d5f7d74 | |||
| b675d01418 | |||
| 17385eeaef | |||
| 23df83cb0b | |||
| 2e471662f4 | |||
| 1e8f4287af | |||
| 21c83670d6 | |||
| 1b23bf495a | |||
| 15b60462a2 | |||
| 1455440efa | |||
| 737da954a0 | |||
| a9a0785252 | |||
| d5561aa323 | |||
| cf37731d5f | |||
| 0765741d99 | |||
| 74338c498e | |||
| ff28d88572 | |||
| 94c7185826 | |||
| 8e075fba53 | |||
| 3b1d1d33b8 | |||
| ac6604730a | |||
| 3cdd9ef36e | |||
| 9aa426a105 | |||
| 5b7cae78bc | |||
| cc98e5759c | |||
| 12ff9af431 | |||
| aa6d83fe1c | |||
| f48ca959f7 | |||
| 59a959a361 | |||
| ce57b26769 | |||
| adc94fd97a | |||
| 1013df1627 | |||
| 646ed5ea14 | |||
| a39e6a2c62 | |||
| fa4f31f3dd | |||
| adb813fbad | |||
| ebe567dab2 | |||
| bbcf49db98 | |||
| 75763735c4 | |||
| 285e5a0580 | |||
| 2ee0c2bdac | |||
| ae58dc846a | |||
| 91f449dff8 | |||
| 2523889765 | |||
| 4c6b146627 | |||
| 6e2d238f56 | |||
| d7a0482146 | |||
| b040654574 | |||
| 505fc25a64 | |||
| 83ba887df7 | |||
| 911f1cb1de | |||
| 1b7aea0ced | |||
| db5eed17b1 | |||
| 1ffb510a77 | |||
| f039393b2b | |||
| 00ba053ce6 | |||
| dcf1f19ff7 | |||
| 06826750ed | |||
| e0a2645f4a | |||
| 509fdf45c6 | |||
| 1e7d897b66 | |||
| 6df0a9ca66 | |||
| 1c12f3a30d | |||
| 3a9e0e34ca | |||
| 8669512f42 | |||
| 313d9d138f | |||
| 040118b7c6 | |||
| b3f48212f1 | |||
| cade0775e8 | |||
| 164aad48c3 | |||
| 04756d05a7 | |||
| 409041b965 | |||
| 11f7187367 | |||
| 4feda4c395 | |||
| a8713da97f | |||
| 199737cd0f | |||
| 3a8f246569 | |||
| 607f079b23 | |||
| cab6b89446 | |||
| 6ed3038312 | |||
| 9b48da459e | |||
| fbd266fad0 | |||
| 240dadff92 | |||
| 290f4a3e65 | |||
| 97fcd9d726 | |||
| df15d70466 | |||
| 680ae8616b | |||
| 4feb8219fa | |||
| 509cc47d3f | |||
| 849b104c31 | |||
| ce3ef13e6a | |||
| c8a73f8c25 | |||
| b71ee13ccd | |||
| a347cdc30e | |||
| 39a88ef650 | |||
| 8b156e25c4 | |||
| eb0c4b3824 | |||
| 56ef0c0735 | |||
| a1a9465e52 | |||
| d64a31fd1a | |||
| 6cdf044320 | |||
| 5307f0742e | |||
| 51326f3d02 | |||
| e1fa99013a | |||
| 72014689e4 | |||
| 2acdf4bb47 | |||
| 85c5b7f19e | |||
| 42ec1a0076 | |||
| 553cc45e54 | |||
| 7415ec32c8 | |||
| 14568562e3 | |||
| cc79d23334 | |||
| ef2b47d180 | |||
| adc056f547 | |||
| 8266a16b4e | |||
| c4a51f4c2f | |||
| 4ddc9c3909 | |||
| 0a2f8abb40 | |||
| 81de5d3f25 | |||
| e6d61e6e14 | |||
| 4fb739615b | |||
| ba39323d30 | |||
| 383937fe69 | |||
| f919f90bf5 | |||
| b4f6f06ab5 | |||
| 73fbca40ca | |||
| e8d3fcac6b | |||
| f87182d5b8 | |||
| 951f8921cd | |||
| d26b7c5437 | |||
| 9407fda197 | |||
| 905913f7be | |||
| 4b8eaac73f | |||
| ca242ff401 | |||
| 42e3c5f39a | |||
| 4f4d2c2f8e | |||
| 5a01798481 | |||
| 8af1eb693e | |||
| 335ccb32af | |||
| e1f2666499 | |||
| 22fcfdf755 | |||
| 1e21b61a19 | |||
| 6abd8bd864 | |||
| 4876ae0e2b | |||
| 63bdf41d40 | |||
| 984cca8b82 | |||
| 9f7ce42c74 | |||
| 16a43bcb6c | |||
| 85d95e3e27 | |||
| 4cce8557e6 | |||
| d60d7674d7 | |||
| 7f9467d1f8 | |||
| d08e3ef838 | |||
| 645c5ff5b5 | |||
| 7975e391f0 | |||
| 565790036e | |||
| 44819b135e | |||
| bb19877430 | |||
| fc02e06423 | |||
| dd8a5dcf32 | |||
| 33584506ab | |||
| ee2cf92479 | |||
| 0b6dd6fb13 | |||
| 993467bb3c | |||
| c7c9f0011a | |||
| 9aa872e705 | |||
| ea5d52cb2f | |||
| b1754f8254 | |||
| 83f08b3135 | |||
| d3d1f94e40 | |||
| fc8572e8dd | |||
| 85acd3d31d | |||
| 9694a68211 | |||
| 0be8b29e42 | |||
| 5580ac9475 | |||
| 84ed66018e | |||
| 4d7f9552fe | |||
| d4b14fd717 | |||
| 0bd15bdab5 | |||
| 0b407c5e6d | |||
| 5f5b82188c | |||
| a17849bc39 | |||
| f3e3a5af5a | |||
| dc71c0d28f | |||
| eb99f5ebfe | |||
| 007fe0ea1a | |||
| 50b04c658c | |||
| cbea89e6f7 | |||
| e2e12fadb0 | |||
| 47eaa513c0 | |||
| 3bbc0fdd21 | |||
| 9393072745 | |||
| e42aa64d75 | |||
| b6935a7285 | |||
| b0367e4a62 | |||
| 0b71bc43a8 | |||
| afeca8cf9d | |||
| 33c396fb74 | |||
| 4903ef7887 | |||
| ab5ab4c675 | |||
| 3ea61d084e | |||
| 2433b2ce99 | |||
| 927758a2a9 | |||
| cb0d018fa4 | |||
| 49f69f6ade | |||
| bcb479aabb | |||
| db59f4232f | |||
| aa625d24bc | |||
| 36cfbaaa22 | |||
| f8462b5218 | |||
| b2bd12a371 | |||
| acf2307eb9 | |||
| 93964ee231 | |||
| 943939ba2b | |||
| f1b5a223bf | |||
| bb9cd37fab | |||
| 972f8c3aff | |||
| 34e522306d | |||
| 7c92c2f7e8 | |||
| 5204bdb60d | |||
| 6ab8d065d1 | |||
| d4e686226b | |||
| 19d7714503 | |||
| f464f30e6f | |||
| 0e7d7d1eee | |||
| 6af66a0201 | |||
| 81f3ad043d | |||
| ca7450f595 | |||
| 65192a7f92 | |||
| 8c309ac9fe | |||
| 7f1ce2aff3 | |||
| 10b67fc7b0 | |||
| 3cd005911d | |||
| d10d96800f | |||
| 35e5f1f204 | |||
| 1efdb72990 | |||
| 8d925d4741 | |||
| d6362cad16 | |||
| 00e83fed3f | |||
| 02f1cc7b40 | |||
| 32a60c2e96 | |||
| 30040332a7 | |||
| 569cbb09bf | |||
| 130191f4ed | |||
| e6732039c6 | |||
| df92c483d0 | |||
| 7c9eefef3d | |||
| 42de1c1dbe | |||
| 395df940d7 | |||
| ef1e18df19 | |||
| e684eae878 | |||
| 5219c5c37e | |||
| 5059abd88e | |||
| e2ed058e3b | |||
| ccc959a2d3 | |||
| a5a7d23792 | |||
| 5bc9acdab3 | |||
| ab1970e7d6 | |||
| 1582714325 | |||
| 7391a4d45a | |||
| 7e16d9b63e | |||
| d49dccb147 | |||
| 6cddfdb313 | |||
| 912316d765 | |||
| b9e2b05f04 | |||
| 887803e495 | |||
| eb11061bd2 | |||
| 000c7a92ed | |||
| 097b26f318 | |||
| 3da5e5e865 | |||
| e60262fec9 | |||
| 74bf1b4bc3 | |||
| 3f69e0db36 | |||
| 7d4c59ac5a | |||
| 3841f05e02 | |||
| bcd409ab1c | |||
| 4dd43aa018 | |||
| aed695313a | |||
| cf299273c4 | |||
| 53323f3cf9 | |||
| 24ee5341ec | |||
| ed4d1554ab | |||
| ac3481ed43 | |||
| 3df5969348 | |||
| ea6a773d60 | |||
| 35a326e169 | |||
| 4020eb9b4c | |||
| 243fe73c57 | |||
| 932f8c48ef | |||
| 7c1be3eb63 | |||
| 5de2cfbfa1 | |||
| b593c00d97 | |||
| 7798e96190 | |||
| 55ac18d90a | |||
| a409db5540 | |||
| dd5d56674e | |||
| 79617570ca | |||
| a4e7cc4700 | |||
| 2fbe4125dd | |||
| 47915816b5 | |||
| 0f53660453 | |||
| f3437dc00f | |||
| 574d63b4fd | |||
| 53e5a04073 | |||
| c51785125e | |||
| 5230f8304e | |||
| e0e00434cc | |||
| b95cb3180d | |||
| dec66dbd05 | |||
| cb44c40a9c | |||
| 2c22f4e17d | |||
| 83fa3593b1 | |||
| 4ad508c04d | |||
| 0d52386236 | |||
| 16a5318d32 | |||
| b1da02dff6 | |||
| b99db92113 | |||
| c0dff1dc16 | |||
| ef6ef506d6 | |||
| b71ac868b7 | |||
| d72997da04 | |||
| 41c0dde9bf | |||
| 498b72f75a | |||
| 5e231f3d61 | |||
| a2fec50500 | |||
| 6d7edb1479 | |||
| ce72f9a84b | |||
| 4fc24e1391 | |||
| 160bddecd3 | |||
| 39810a520c | |||
| 0dc47609b5 | |||
| 8fb4636cb4 | |||
| 30cf3dbbe6 | |||
| c90e9311e3 | |||
| ba2a7e4417 | |||
| 740dfa58a6 | |||
| 9620b15ea1 | |||
| 3fab7a341d | |||
| 5804547bc5 | |||
| 70d0d20750 | |||
| 92e21c275c | |||
| 8aff08581f | |||
| 6eb0de42f8 | |||
| 8c4a0b61b8 | |||
| 22696566d6 | |||
| c5c2938380 | |||
| d6433de4a6 | |||
| 15eaac35a8 | |||
| 46f3196297 | |||
| 842e5a6774 | |||
| 2ece368810 | |||
| 1bbfc56121 | |||
| 835b252b5d | |||
| 9bc9fc4545 | |||
| 8cc5338870 | |||
| 9191003391 | |||
| 99236fd93b | |||
| b34d560bb7 | |||
| 7bb4ddcfd5 | |||
| 00190abad8 | |||
| aa8eabd853 | |||
| 4914517f6b | |||
| 0865dbbf75 | |||
| d3a3ad0228 | |||
| e075432c40 | |||
| e816ab05de | |||
| a4762d0e02 | |||
| 2329622564 | |||
| 368312c816 | |||
| f6dbe1a40c | |||
| 032d085619 | |||
| a6fff37be8 | |||
| 879283685d | |||
| 0f4f2a6672 | |||
| ff6f5ce237 | |||
| dc0467e934 | |||
| f0d22fe570 | |||
| 05ee4d489a | |||
| 3c1ded22fd | |||
| bda5d252b2 | |||
| 0c3e66d6a0 | |||
| f31bf76f94 | |||
| 0afedee49d | |||
| 43d439a1cd | |||
| b8aeb4f0ee | |||
| 1408385612 | |||
| d6471d7d51 | |||
| aa9d66c53c | |||
| d9a7ee3e29 | |||
| 04c70f2037 | |||
| 2198f0cefe | |||
| c6b9b4d326 | |||
| 4c6ebe7808 | |||
| a9090e4a72 | |||
| 0126eb5470 | |||
| ed63617aa0 | |||
| 30f483a524 | |||
| 894f202b75 | |||
| 9171585b2c | |||
| 23d8ef32a3 | |||
| a031e112e5 | |||
| da8297d770 | |||
| 3991eb053c | |||
| 6fb26c44d7 | |||
| fdc027734c | |||
| 32a7f6a0f0 | |||
| 5bbec48679 | |||
| d4b9ee4c61 | |||
| 50b5cd50bc | |||
| 53afbd0f05 | |||
| b6874eb66d | |||
| 7ff7de4643 | |||
| 5f148632d2 | |||
| c1325ef9a3 | |||
| d788b7ff5e | |||
| 66d0663dc5 | |||
| a56524ee05 | |||
| 1aa9f2809e | |||
| 261672e84c | |||
| 6a4e39e815 | |||
| 4af9ce8a81 | |||
| 5f146720fe | |||
| 67e6772d88 | |||
| 12e9febe9e | |||
| 676022eeb6 | |||
| 3a8fc1e70d | |||
| 0b6798acb5 | |||
| e721124b6c | |||
| b32eb30212 | |||
| 967a39ecbe | |||
| dfb7f5abfb | |||
| 56f5d5125b | |||
| 5083174a92 | |||
| 4a278dfd79 | |||
| 80d57ed8f9 | |||
| b742e222d6 | |||
| ae86f66545 | |||
| 45e4c9e16c | |||
| 8c07f1a42c | |||
| e6c97410ef | |||
| b1a55c7a32 | |||
| 1cd1449085 | |||
| 55690f3738 | |||
| 13f6fb1929 | |||
| e8088a6563 | |||
| e8051bad9a | |||
| d0d41a63a6 | |||
| 853b038a47 | |||
| 34946f6105 | |||
| 15d88c269d | |||
| cbbfd85eeb | |||
| adf90c876f | |||
| b4f76b8448 | |||
| ed858ebd4b | |||
| 272b9c7afd | |||
| 8dc8dd9756 | |||
| a64d1001e2 | |||
| ad737ded3c | |||
| ac6b0c0980 | |||
| b69e0ff9f7 | |||
| 0361f9f7de | |||
| 005668aca8 | |||
| 013f8b216a | |||
| 8ecfa91e5d | |||
| 117fc6eda2 | |||
| d66af122c7 | |||
| a7467945ca | |||
| 81d8aa55cd | |||
| 4a6630138d | |||
| 3adae3a9aa | |||
| 21ebf48072 | |||
| 2b90bcfab6 | |||
| 5f0641f348 | |||
| 38c9cac578 | |||
| 9ba49fa454 | |||
| 39fede66e6 | |||
| d984f1a9d8 | |||
| 28b8efe00c | |||
| 7b0fd6de9b | |||
| c0fa2e3a73 | |||
| 3f6669e2b7 | |||
| 6ff4ed84e5 | |||
| 5e72b03b0a | |||
| 4bb88027d8 | |||
| ae4f14c2e2 | |||
| 5a8b33fa09 | |||
| 5884a0e05f | |||
| 31e44062a8 | |||
| 87cb1c9b8e | |||
| 0266d24d0a | |||
| 0876e00eb8 | |||
| 85c4794ceb | |||
| e007bf35b2 | |||
| 74e968e93b | |||
| 18507fb836 | |||
| 3b245837b9 | |||
| a853984f52 | |||
| 00c544ee99 | |||
| e7b9e41a5e | |||
| e254b4f3c0 | |||
| b0c9c68c9c | |||
| 1030434ce6 | |||
| 2f08c4b00f | |||
| 4553f90a83 | |||
| ef7fec7e24 | |||
| 0a76b9c61b | |||
| fbeb8f81ac | |||
| 62af4f1c2c | |||
| ed43efe4fb | |||
| 1cb42c32e3 | |||
| 628b454ebc | |||
| 38a858d7d3 | |||
| 83b92ddfa4 | |||
| 7cd415b1df | |||
| d2113b4d23 | |||
| d445987f95 | |||
| 14d2d747f6 | |||
| 73dc8c9c4b | |||
| 576f1a798c | |||
| 78fa2d2e3b | |||
| 9402cc8c6a | |||
| 7d1a508ea9 | |||
| b84034b667 | |||
| 84b7cbd992 | |||
| bc8ca912ce | |||
| b61baa1efc | |||
| c4a5bc8584 | |||
| 8c71d579b5 | |||
| 2e8d8f63ff | |||
| 91b94878d3 | |||
| b000aa3dfe | |||
| 582c6eaef9 | |||
| 4f4109cdb6 | |||
| 9f12673631 | |||
| d37b75442d | |||
| ee58255418 | |||
| 033ba588c9 | |||
| 60d8283971 | |||
| ad90bc2809 | |||
| a1b9eca7b6 | |||
| c4a5b8ca94 | |||
| ab79134309 | |||
| 63c3e8396b | |||
| 1793bf0863 | |||
| 8e0e87877a | |||
| 425b31c6fd | |||
| 4da469325d | |||
| 33fdde6afd | |||
| ee6103418b | |||
| 038548c188 | |||
| ce8b536fca | |||
| 8e5a03f6c9 | |||
| 1c5fd1a1f7 | |||
| 2598745e50 | |||
| e756f284be | |||
| c6a02b850d | |||
| 55e8dbe9fd | |||
| 5efa5ebd2f | |||
| 4ebe4233fc | |||
| 35623b5abe | |||
| b617d399b6 | |||
| b96b5c3f7c | |||
| 847f016cc9 | |||
| c613dc8c5c | |||
| 182a393050 | |||
| 6cb91021cf | |||
| 2be9bb970b | |||
| ea396a3925 | |||
| b1611fee1b | |||
| dba903c13b | |||
| 7cb5fbe684 | |||
| d7ae5624c8 | |||
| f1455ad37a | |||
| 127e8af6a6 | |||
| d9be1d0b52 | |||
| 6cd84e8276 | |||
| ceaeceadd9 | |||
| cd5bf7c504 | |||
| 66aa0c7050 | |||
| 141ca62c6d | |||
| 9dc97f4b0d | |||
| 714bda3e0f | |||
| 2b4598f65b | |||
| 5e9ef8ada4 | |||
| cf7c07cc34 | |||
| 508062f8dc | |||
| e5c63c7e16 | |||
| 7a11f00eb4 | |||
| faf09c586c | |||
| c866b5005f | |||
| a0619f7ff0 | |||
| 37aee19bfa | |||
| 27609d8da8 | |||
| c083b333d8 | |||
| ee376883d1 | |||
| 98169784b1 | |||
| 9d1c6f2daa | |||
| 25d4ba320a | |||
| 3988a7ff6b | |||
| 26e3c7aeb8 | |||
| eff46bd1db | |||
| 7a3176ea77 | |||
| a656ad0941 | |||
| 299573dd19 | |||
| 43b84f4044 | |||
| 897d6d9ad0 | |||
| e4c8cfc16b | |||
| 95888e0b77 | |||
| 4ded89d453 | |||
| 82a3391937 | |||
| f580b7a488 | |||
| 9df0a9da0a | |||
| 6172862061 | |||
| 1ae037f515 | |||
| 6f7cd96a7f | |||
| e00d3ff7ff | |||
| 390b936153 | |||
| 863bea1ad1 | |||
| b7794a8783 | |||
| bb3c51c6cc | |||
| c3c82cebd5 | |||
| 5d51e9fa2c | |||
| 2c70bb6a00 | |||
| 98b2e8ab18 | |||
| 675ae9bade | |||
| 3e7e8ba6f2 | |||
| f1766bdbdc | |||
| e3665cedaf | |||
| dd7caea910 | |||
| 8ed57c6468 | |||
| 0e6becc36d | |||
| e38c455252 | |||
| 4c1cf73005 | |||
| 384fb3c4d5 | |||
| afb90b0af3 | |||
| 1530ffc926 | |||
| f876a56d2a | |||
| d26eadf5be | |||
| 13fc0cb9eb | |||
| 59b3f6e962 | |||
| 80442efe94 | |||
| ab929e465b | |||
| 047c90466d | |||
| 40e6b2b0f1 | |||
| 9159f00014 | |||
| 59a9484970 | |||
| 8a853b1bb7 | |||
| 2bcd6c4771 | |||
| 1acc1b8230 | |||
| 2c169e2330 | |||
| f57d71b6fa | |||
| 796bc008f8 | |||
| d7faae0531 | |||
| f0511592b5 | |||
| 68efab79ef | |||
| 1ede8c77ba | |||
| 48f95d0009 | |||
| 0bb57b8989 | |||
| 0503c17867 | |||
| 19779cd342 | |||
| 141f3512a9 | |||
| 3b9e5c71bf | |||
| 2bcee014f7 | |||
| f0568b4e22 | |||
| 8670f29c4e | |||
| 33a528af76 | |||
| 52056644d4 | |||
| 3ae23df4b3 | |||
| 1b327b8abd | |||
| bb5cd3e224 | |||
| 1e8237446e | |||
| b2b2044786 | |||
| 64c5222623 | |||
| 1597291ac3 | |||
| c2e742335b | |||
| cf5884bc60 | |||
| cbf5ee9649 | |||
| 8ac177a6de | |||
| cdd4473df5 | |||
| aaebaa7250 | |||
| 7443a8baa1 | |||
| c6ff95a3f4 | |||
| 7957016ae2 | |||
| 17ab0e2ced | |||
| b0650f3402 | |||
| f4f73f2765 | |||
| babc69e13d | |||
| 481c50f233 | |||
| b62b2f3598 | |||
| 4f37abac6a | |||
| 31a23e724d | |||
| 7d5ab1f8db | |||
| 0d8952dcde | |||
| bd7ec5d0b0 | |||
| 9e6e8001ca | |||
| 0639becccc | |||
| 88844649eb | |||
| 31c5d5a5f5 | |||
| 6abbc57c96 | |||
| 39af6e51c4 | |||
| ef04c8a09e | |||
| 4505d61604 | |||
| 04d32e7a91 | |||
| 26066965c3 | |||
| 7f199527f8 | |||
| ea79b3cbb8 | |||
| 0ca81bd11a | |||
| 4d13ffdc26 | |||
| 331a29024e | |||
| 6aa5c2b2ef | |||
| 8c969b2a84 | |||
| 0d7e28ee75 | |||
| ab5062663e | |||
| 896b9fa105 | |||
| 6a01275499 | |||
| 61bf0a0092 | |||
| d7c5a08d20 | |||
| 350ee9f0a2 | |||
| 7753fc6fe1 | |||
| 24f5b2782d | |||
| 853d7aaf8f | |||
| 07509e9847 | |||
| ab82599ee2 | |||
| 10e2b60ad9 | |||
| 965476c7f4 | |||
| 9536b33a6a | |||
| 61271e4f7b | |||
| 57941b6df9 | |||
| 1102de5a66 | |||
| 6d33a73617 | |||
| cdcb0cdc14 | |||
| 6176028176 | |||
| c871bb3a1e | |||
| 3430cf1f17 | |||
| 4556dda038 | |||
| 49042d480c | |||
| b7295a1558 | |||
| 62d91438f2 | |||
| c4c3620c5f | |||
| ec0cbab47e | |||
| 8e3c66584d | |||
| 84e75129a5 | |||
| 26d460241d | |||
| ede54b392e | |||
| d12542d78e | |||
| 3a014dcb09 | |||
| cb27f26e64 | |||
| a3ad294d6a | |||
| cf57ea3ef0 | |||
| 94dd590fc4 | |||
| 27836feb47 | |||
| 96e48e1de6 | |||
| d5c06664b5 | |||
| e4edbe25b2 | |||
| 31bc30bb27 | |||
| a2905977ec | |||
| b63e01adf6 | |||
| 2680666f52 | |||
| f82f53f5f6 | |||
| e27ca17b0e | |||
| 066b1026a2 | |||
| c7cf72e7bc | |||
| 0e2a0075ef | |||
| 6dccaf802c | |||
| de5224689a | |||
| f9ec01c647 | |||
| 4902eb73b7 | |||
| 513c8605fb | |||
| 84148bbbb0 | |||
| c2e91edca8 | |||
| 17fc1ce174 | |||
| be9377a496 | |||
| c40a4d8a66 | |||
| 6d0b4faeb0 | |||
| 3297924992 | |||
| 059c62a6c0 | |||
| bef942b19f | |||
| 30140fb229 | |||
| df3ae386cb | |||
| baf4cc1d1c | |||
| 9fcd3374c1 | |||
| d5d56e51d7 | |||
| 3b8853736d | |||
| 16b22e7505 | |||
| da7eac03ad | |||
| 060f67c2c8 | |||
| 273b81d60f | |||
| 72b58ff8a1 | |||
| 900e0b2751 | |||
| 9026fd2c13 | |||
| f6f0c8fd1e | |||
| 4bdaacab91 | |||
| 60ca7d7246 | |||
| e4e312c4f8 | |||
| 7bcdbae7b8 | |||
| b16cd2dc85 | |||
| 0826f8ba35 | |||
| ead284e20b | |||
| 59023f9f09 | |||
| 17e48ba9f2 | |||
| e60b42470e | |||
| 9c42ba187d | |||
| c6f14dc1b1 | |||
| 02e3240bb1 | |||
| 54f0968f86 | |||
| 0e75d39811 | |||
| 6cf6414da2 | |||
| 89f77a2412 | |||
| a400d8b2f3 | |||
| dc6a9237d7 | |||
| 2c73ba2f76 | |||
| 2cbfdf43cf | |||
| 5e0e6f356b | |||
| cbff244d88 | |||
| 2e405342ca | |||
| 583d576cdb | |||
| 3db97ba0dd | |||
| e81d6a859b | |||
| 534abb7f17 | |||
| 7198eb3b66 | |||
| 32f33b9f8c | |||
| 03ad6a5728 | |||
| c1308475f3 | |||
| e4ec1be948 | |||
| c90f91dcbe | |||
| 5332ce4c79 | |||
| eaae7f46d2 | |||
| 8c40a53b80 | |||
| 25c091df7f | |||
| ec3a4532b8 | |||
| ad04adccea | |||
| cfd2636f13 | |||
| 7e854f88ca | |||
| 3628b1e9d2 | |||
| 68e75c589b | |||
| 9ad9292321 | |||
| 7fcf7d31a0 | |||
| 0cf28c0f07 | |||
| abbc96a873 | |||
| b7201e111d | |||
| a31553468c | |||
| ce89b440bb | |||
| 3a72c4a507 | |||
| c82e612258 | |||
| ae5891068e | |||
| f326dc4eaa | |||
| 48fddcd5e7 | |||
| 33c9204d58 | |||
| 99f1e69469 | |||
| ed0b3c039a | |||
| eef25c28b4 | |||
| a32847f0c5 | |||
| 0fc193faa3 | |||
| 65077a224c | |||
| c256d2d4af | |||
| 215a50675e | |||
| 023c4a19ae | |||
| ac5d399906 | |||
| 7fd0e5b3bc | |||
| 64ff651d57 | |||
| d260de15ba | |||
| be77779aff | |||
| e119f2a534 | |||
| a09c8497bc | |||
| ebad3eb93e | |||
| e4e4534c7c | |||
| b412fc6516 | |||
| f9c9750108 | |||
| 5dee3bb4d9 | |||
| 1e3d8cdadd | |||
| c5bf45f1ae | |||
| bf674060c0 | |||
| 878dbe4ab9 | |||
| d8b383719a | |||
| 9ff5f39701 | |||
| 5144cc0e08 | |||
| ee29b28575 | |||
| 7785082f19 | |||
| edf40ba430 | |||
| a228495ced | |||
| ed9dc70769 | |||
| e8581d4fd5 | |||
| 2d6fcf5d06 | |||
| 55e0262c37 | |||
| d5e5a48170 | |||
| d0f2928cec | |||
| 190a53647e | |||
| f9a3fa3c23 | |||
| f1fee72d6d | |||
| 0b4ae6b116 | |||
| a1ec7cb896 | |||
| 1935412db9 | |||
| c90a9d45ee | |||
| a594592151 | |||
| 119d8bf98c | |||
| 1e141d9f64 | |||
| 587af6dec8 | |||
| 793e862e5a | |||
| 09c3425dd3 | |||
| 4ca168412b | |||
| 66f24db6da | |||
| c39a58f812 | |||
| 5034f231a9 | |||
| 1a271ce627 | |||
| 64afd5f64c | |||
| 0e0d2e1c45 | |||
| 52d8371ba9 | |||
| 1d74b58d36 | |||
| 66803fd664 | |||
| 87609a3424 | |||
| b4184e4523 | |||
| 05508e4fcb | |||
| 372bae4799 | |||
| c7f51b8e77 | |||
| 21f48d3750 | |||
| b57cbacc82 | |||
| 126a81d89a | |||
| 707dc6b346 | |||
| c1c86c026f | |||
| 5c4982cb0c | |||
| fed38ea7ab | |||
| 4d6ef1c52d | |||
| c6aba6da4d | |||
| ec92d2b7f4 | |||
| 6810e71220 | |||
| f4192d695c | |||
| 6664437b06 | |||
| 96a135834a | |||
| 09ba1bf1fb | |||
| cc01629b57 | |||
| 2d586859c3 | |||
| a5e20e4939 | |||
| 0e3f4f45e0 | |||
| 045c3e132f | |||
| 80c068ae05 | |||
| 6574b8cbfe | |||
| 20c48b1712 | |||
| ee16b6df88 | |||
| 325887fa18 | |||
| 73ca527b0a | |||
| 439350836e | |||
| 5ee387672b | |||
| f670c24e2c | |||
| f2e1f63396 | |||
| 6dacdd60dc | |||
| 87ccc27ee4 | |||
| 147348e0d1 | |||
| ad202ea735 | |||
| 950695664c | |||
| d1f76f3834 | |||
| 66e6a05e5f | |||
| 0f430c66ae | |||
| 8357b0f649 | |||
| 7fc75bfeff | |||
| d7bd1b74e8 | |||
| d7764e2968 | |||
| f865d6fa6a | |||
| e6bbead4e6 | |||
| 5f3a525d11 | |||
| c5d80a2192 | |||
| 97b8f0f781 | |||
| bceb5fc7de | |||
| b3e66d8023 | |||
| e06f831205 | |||
| 60340a7348 | |||
| dccfc1c8cd | |||
| d58186372f | |||
| d32246275a | |||
| 2eec1bc61a | |||
| bbab9f3934 | |||
| 09a3f23e3d | |||
| 329f6b90f7 | |||
| a4ab9c284f | |||
| 9e056dfac8 | |||
| d8d9996464 | |||
| 43992a137e | |||
| 7767bf4d5d | |||
| acd1989fa1 | |||
| afa1f78a02 | |||
| 87b1433473 | |||
| 5813979479 | |||
| ba7cbfe3d9 | |||
| 546b6b1724 | |||
| eca3583845 | |||
| 2471130f59 | |||
| f5693c4393 | |||
| 12eb3ac63e | |||
| e3f0163092 | |||
| 213392640c | |||
| 4382a6e7bc | |||
| c200177af4 | |||
| 465100ae41 | |||
| 3d6867c321 | |||
| 3d5ff3b250 | |||
| be47203732 | |||
| 1625fc6f7e | |||
| fa57634505 | |||
| ac71658b4b | |||
| 61db7d96b7 | |||
| 5ee297d999 | |||
| 6301403777 | |||
| 95881d7616 | |||
| 85d8f90d81 | |||
| f6054ab37f | |||
| 5537930210 | |||
| 920dbbef5e | |||
| 2510e0412d | |||
| 2302f88847 | |||
| 4f95d0a07a | |||
| 8f326dcac5 | |||
| aa294ea5df | |||
| 6afc725b61 | |||
| ec01693773 | |||
| b0cf501782 | |||
| c2fb7ada0a | |||
| d0a8e60ace | |||
| ab36bb8842 | |||
| 0b3cd7b7ae | |||
| 10ed04cdb8 | |||
| f08c18594b | |||
| e09704a408 | |||
| ade9ae3c0b | |||
| 9cf6124c4c | |||
| 6d323cc529 | |||
| aea9f6fe18 | |||
| 8a27463e44 | |||
| 47ee2cba51 | |||
| 531cc7b864 | |||
| 54bdabd94d | |||
| bb6e8fe7a8 | |||
| d5d199ebef | |||
| 158a4589d2 | |||
| 84c0f456c0 | |||
| 3fcd6ef877 | |||
| b5855037f3 | |||
| 4e2d378145 | |||
| 38a7055017 | |||
| d64898c59a | |||
| 3bff71b3fc | |||
| 8343d1cd0e | |||
| 5c23c0cecd | |||
| f580713478 | |||
| 3c58b8d7fa | |||
| 072d5f9760 | |||
| f8067f5dd5 | |||
| ea354d10cc | |||
| 4d5b41434a | |||
| 1724a26957 | |||
| cb69fbcbd6 | |||
| 46dc68dfd5 | |||
| 12fdfbf8b2 | |||
| 992a986d12 | |||
| 68bdf7deb4 | |||
| 2362c453ec | |||
| 50f6b6e0f0 | |||
| 88a9eef8a6 | |||
| eb533f3344 | |||
| 308e13a546 | |||
| a0b1fefdbb | |||
| 3edbcb7bf9 | |||
| 436931b560 | |||
| 0516159ae3 | |||
| cb78953b38 | |||
| a1ddac4e6b | |||
| 456697ea99 | |||
| 8acffd1186 | |||
| 814450fd17 | |||
| 1365c1d277 | |||
| 30be5c5e49 | |||
| 932cd9d5bb | |||
| 7b5f17c16b | |||
| b5e8e68713 | |||
| 3a803ac39f | |||
| d27db119a0 | |||
| f54d0a339c | |||
| 5e3c0bd9aa | |||
| d83b676c60 | |||
| def3dc364f | |||
| 298aa5f040 | |||
| a6bbb8424c | |||
| 00daeb318c | |||
| 65341141fe | |||
| fe353c5fe3 | |||
| 008e5ea196 | |||
| 157e936f24 | |||
| e4d56e7ad9 | |||
| 8eb9fdfcd0 | |||
| 3db5358dcc | |||
| d1fe0670fc | |||
| ee614f9c6b | |||
| 0fce4edcd3 | |||
| a34f52ae5e | |||
| da465bb030 | |||
| d23b24dfba | |||
| 22941276a5 | |||
| 20a50cb198 | |||
| f0cd3c084e | |||
| d9c1e1f576 | |||
| aa6705f493 | |||
| 3f526c3819 | |||
| 6f5058c9b6 | |||
| 4935416b94 | |||
| afa58ed45b | |||
| 455d724c01 | |||
| 42bccb4c23 | |||
| b2b0a1828e | |||
| ea60f7e054 | |||
| daf2b649ef | |||
| aa87d234e3 | |||
| 5eec9ce7b1 | |||
| 7812f41b43 | |||
| 0bd3537a78 | |||
| fdf09b5978 | |||
| 17d7c92b9d | |||
| b6a7788240 | |||
| 00ccce7bb8 | |||
| 54b564b871 | |||
| 5882a9dc21 | |||
| 144249fcff | |||
| 31ce55eb4d | |||
| 255b502460 | |||
| 073869b354 | |||
| 9fdf20b3e2 | |||
| 2461ef9f29 | |||
| f8f13bd905 | |||
| 948cb9ff7c | |||
| fa39b9ee54 | |||
| 6d09328d6d | |||
| 77fc8866bf | |||
| a5cc03ff25 | |||
| 5ab959ba58 | |||
| 86b90ed4b6 | |||
| 6ffdff7095 | |||
| 37c6320dd7 | |||
| 33367fd3ee | |||
| 3a1cd3d588 | |||
| 4fc27f6509 | |||
| f0b78253b2 | |||
| 2428b27168 | |||
| 01ba56c38b | |||
| 887cad3b96 | |||
| 14268aa1c0 | |||
| 23c00eb83f | |||
| 5f2047d61b | |||
| 1f9d86f015 | |||
| 8cb6086f73 | |||
| a887cedb99 | |||
| 1fb9be0628 | |||
| caf03b223b | |||
| f77d388d4f | |||
| d0cfeb2a8c | |||
| 0a6e4ebf18 | |||
| dd34892857 | |||
| af39eb4c9f | |||
| bd4948c084 | |||
| cea6cbc7db | |||
| 54ccbfef98 | |||
| 88b124b29a | |||
| 7eff3bc697 | |||
| c3161d58fd | |||
| e2a0cb97ae | |||
| 4fae47db63 | |||
| 48b5f37894 | |||
| ff1755d2db | |||
| f13ccd8527 | |||
| a97d74b15c | |||
| 8b48f16508 | |||
| 04eb654133 | |||
| 1a000396e2 | |||
| 3a658cdb85 | |||
| 3cb578488c | |||
| c845d1d93d | |||
| d322e67117 | |||
| 9ff17810a4 | |||
| 5f87591407 | |||
| 65c385c013 | |||
| 8094968605 | |||
| 7ac9c46f12 | |||
| 01b9fa8ac9 | |||
| adb4a1e6c0 | |||
| c371e5221a | |||
| c9529199a1 | |||
| f2e7f18d61 | |||
| 96044822a0 | |||
| c469d0277f | |||
| 221082b967 | |||
| 2c2acfb5b8 | |||
| 76b819ae3b | |||
| 43f1354e79 | |||
| 6e1c76efe6 | |||
| e517bf7b0e | |||
| 3b811c3434 | |||
| 9e3a49dd1b | |||
| 65d1648c30 | |||
| a4d80bf743 | |||
| a15ec0d677 | |||
| 7e5301c845 | |||
| 795ac4773e | |||
| c75cce0378 | |||
| 5760289d2a | |||
| 619e256138 | |||
| 7401fb09c9 | |||
| bb37e5ac88 | |||
| 69935f3d1c | |||
| 3dcd9b535b | |||
| e90f72b538 | |||
| 9efc2894d4 | |||
| 07c5ce0bbc | |||
| 3bbbe1db9c | |||
| d7b94428ae | |||
| 033e2c1d78 | |||
| 9345eb5e94 | |||
| 220ed74ad1 | |||
| 658ca8c0fd | |||
| 56f88f759a | |||
| ee1585fb24 | |||
| c72a9f2e1e | |||
| d4b502f14e | |||
| d32acabcef | |||
| 4943c3a9e0 | |||
| 58290ec9ea | |||
| 6468d55a81 | |||
| fe93d7b332 | |||
| 067514b74f | |||
| aff2fbdc54 | |||
| 805f60efa1 | |||
| b0b1b61280 | |||
| c09f22242f | |||
| 9892cc46e4 | |||
| 6e12aa4bf7 | |||
| 8731123030 | |||
| eaeb8e03ab | |||
| 6ded700f92 | |||
| e5613e8690 | |||
| 45fbb5326c | |||
| b09f4e9240 | |||
| c2f2ad7a28 | |||
| 0534994fa8 | |||
| 9486f6e7e9 | |||
| 343985ad12 | |||
| 0f67559995 | |||
| 280c3b4a86 | |||
| d4cb1666e5 | |||
| bc29e86e58 | |||
| 2e76268005 | |||
| 9abaf744f2 | |||
| 6232c873b8 | |||
| a3bab8db55 | |||
| d30862373e | |||
| ee4ca43bd5 | |||
| 3bed3e4f5b | |||
| 0dc1adb672 | |||
| d045b4d2f5 | |||
| 572e71d76a | |||
| 09f83bdd58 | |||
| 61c9d5fb3f | |||
| c91b83969c | |||
| 47cefbf6d7 | |||
| 4cdddbd6e0 | |||
| 99455e328b | |||
| ee25d696eb | |||
| c17530a6db | |||
| 0a7e4be4ef | |||
| c1586a3b81 | |||
| 09f9d1cb7a | |||
| 00692c50da | |||
| 4663978fde | |||
| 130a67c72b | |||
| fd5b0fdf49 | |||
| f04715bccb | |||
| 3932e0b15f | |||
| b00de2c617 | |||
| 14e96069f2 | |||
| 079cf9d7b8 | |||
| ca5c0cc84d | |||
| 984e5f98f7 | |||
| b79e4a3ab7 | |||
| fab17f89c4 | |||
| 48c5c1e5a8 | |||
| b9bb1ecd46 | |||
| 2a8e2f9f2c | |||
| e5f1b74bd9 | |||
| cafd9098d7 | |||
| b39b2374c4 | |||
| 739490c62b | |||
| 8de8a0c97a | |||
| 44089d70d4 | |||
| aabc1f8322 | |||
| 09493bbc36 | |||
| e389d73c65 | |||
| a9647a7bf3 | |||
| ce93b625d4 | |||
| bdf8244f7d | |||
| 7e81600772 | |||
| de17302ad0 | |||
| 25bdf10cc8 | |||
| 02c6deaec8 | |||
| 63d384b676 | |||
| 29a996e70e | |||
| 4978955404 | |||
| a7c4597c97 | |||
| 57a1a7607a | |||
| 31772d5eac | |||
| 77422f71f7 | |||
| 40225c5352 | |||
| ad48dc025b | |||
| 1215f67aac | |||
| b9907ae3ba | |||
| 656d1bbbd6 | |||
| 20c0e6d68f | |||
| b27259aded | |||
| 3658faafae | |||
| 0b05c9e3e7 | |||
| f3c25ecba9 | |||
| b9d6ac26d1 | |||
| f583f28953 | |||
| b6d60fc209 | |||
| f72ba0b64d | |||
| 8f24dc3549 | |||
| 4de74464ac | |||
| fa45715416 | |||
| df68ce23d2 | |||
| aee52fd56e | |||
| 000483cc6f | |||
| f4e8eff813 | |||
| 4143722f6f | |||
| b0675400e3 | |||
| eb5332ea11 | |||
| ff2e9b568b | |||
| 19c9f0a488 | |||
| 90e116fb9e | |||
| e28be8d114 | |||
| 36e05561cc | |||
| bc2ce19876 | |||
| 4c7e409e61 | |||
| a4bb80b6fd | |||
| bb1a95fff8 | |||
| 937845e67d | |||
| 7d84ab761b | |||
| 80daed6bdf | |||
| 1015fb5338 | |||
| e401ba0f43 | |||
| b4e6abc460 | |||
| a1fb5f18dc | |||
| 780d06b19e | |||
| 3a20883a81 | |||
| f0c25d8476 | |||
| 34e7913268 | |||
| e10ba4cf67 | |||
| 39bbca2a50 | |||
| e02bdd875d | |||
| 3f24159636 | |||
| 4769fbf383 | |||
| f25f8e8033 | |||
| 6a7722995e | |||
| 892619678e | |||
| 8a2f49a4d2 | |||
| 57a939e10b | |||
| 01930c9899 | |||
| 4f0b45aeac | |||
| b7b71795a4 | |||
| 9c41f2e3f8 | |||
| a8d6363e79 | |||
| 5dcdb66794 | |||
| 0c1de766bc | |||
| ad64a29145 | |||
| 885ddd36fc | |||
| 6a82fdb888 | |||
| 02f01323f9 | |||
| 5af426d265 | |||
| 10fc81f716 | |||
| 4b168f5579 | |||
| a0a9ecfa20 | |||
| ff36667dbc | |||
| 667b6aa4ca | |||
| e11698dc2a | |||
| dacc19ac98 | |||
| d330e9ac8f | |||
| 85d01f3d9e | |||
| 15fd815144 | |||
| 68a8a456c9 | |||
| 2bb80593a7 | |||
| 58992fa0ba | |||
| 0e3a8576b4 | |||
| 8586f31e03 | |||
| bca467cd15 | |||
| 21215f6b2f | |||
| cb6095dc17 | |||
| 8121b9c794 | |||
| 66450b0ecd | |||
| a4d7cf14a7 | |||
| 65fde53083 | |||
| acb2bc7d99 | |||
| 7b9a03d13c | |||
| b6df7b94d0 | |||
| 71399d1f65 | |||
| 0da5535bda | |||
| c74a33f04a | |||
| ecfedff32a | |||
| 34bf315623 | |||
| 3f030b1f6e | |||
| 8de176d73f | |||
| afc3367f31 | |||
| f56c2ed356 | |||
| e2fbce0420 | |||
| 80e8a58f45 | |||
| 26ef8c5872 | |||
| b840405af6 | |||
| 6aa39b3451 | |||
| c1b75b9071 | |||
| 65e1048715 | |||
| 9ed6ebbcff | |||
| e615528f17 | |||
| 261fa7e843 | |||
| 5ed5adc6df | |||
| 632b7f34ae | |||
| 9659f45fbb | |||
| 30a597cadc | |||
| e4e98caf8f | |||
| 6b5f111b6a | |||
| 8f0c0337c5 | |||
| d87413fb23 | |||
| 0340fb7124 | |||
| 6c19844a2f | |||
| dd0045e36f | |||
| 6acb2f46e6 | |||
| 578d8218bd | |||
| f754bdbb0e | |||
| 3ff77a87d4 | |||
| 2ead7606b2 | |||
| 1fdf85e3b8 | |||
| 18c4082bd2 | |||
| 45e9e108bd | |||
| ec55463856 | |||
| 8944635bf9 | |||
| c4b45d2400 | |||
| b444a661c2 | |||
| 085ac39231 | |||
| f5bd5a8748 | |||
| 478f901595 | |||
| 5073413ffc | |||
| 7bdb4fe660 | |||
| bf8afc96e4 | |||
| 817c3ce698 | |||
| c33378540a | |||
| c160500c7d | |||
| 35cf228d83 | |||
| b0eb76359e | |||
| 16a05f1450 | |||
| 1749af1416 | |||
| ae7685278d | |||
| b63786cd75 | |||
| e5c3444ea6 | |||
| 0ded168715 | |||
| a7b78b00b1 | |||
| a0c139f6a7 | |||
| b649c5aca8 | |||
| 56c13c2abf | |||
| e21cd301c2 | |||
| 656fb99b6a | |||
| 1725d247ae | |||
| 85aa850539 | |||
| 2cae1412f9 | |||
| f78d65833b | |||
| 2c542cfd46 | |||
| ab1f64a83e | |||
| 9105590c69 | |||
| fe1ca3cc22 | |||
| c906990b63 | |||
| 23f13c0f6a | |||
| be0df90d05 | |||
| 65b6fbba84 | |||
| 58a2e5a3b3 | |||
| 2866ee75a1 | |||
| f91b5b558a | |||
| 0db3a9f0f6 | |||
| 8442bab164 | |||
| 332de30fba | |||
| c5541b484f | |||
| 7b22355abb | |||
| 09be476fd9 | |||
| e2abee7ba4 | |||
| 6d62e071e4 | |||
| af289bcc7e | |||
| c12404b378 | |||
| 8a22b129dd | |||
| 28fe100761 | |||
| 0622b517c5 | |||
| d7da2b5657 | |||
| 5415d6dc52 | |||
| 1978a262a8 | |||
| 9e21052a3c | |||
| 9748b9f70b | |||
| a237495b66 | |||
| 00ac9069ee | |||
| 7e3d7b3575 | |||
| a96acf6eed | |||
| bbc43520fb | |||
| cea6e4c3d9 | |||
| 7e56bf700a | |||
| 2728ab9e42 | |||
| 3be19e58e1 | |||
| 82ea10a59b | |||
| 86a1721326 | |||
| eaef2d865e | |||
| dc1ad3dda4 | |||
| c94513f4aa | |||
| bae18a92b7 | |||
| a3dfebffb4 | |||
| f5920fff68 | |||
| e15a862cd2 | |||
| 22b7b2b953 | |||
| dde4b75022 | |||
| e936b376fb | |||
| b58c5311d0 | |||
| dbee5810dc | |||
| 8ea4b71e7a | |||
| 3e5b3a6dad | |||
| 61bc38fff6 | |||
| c047214a33 | |||
| 7d75f6e7c5 | |||
| a99cc34243 | |||
| 8db890c510 | |||
| 1db2c31ecc | |||
| 49edad0216 | |||
| 51fd87bc01 | |||
| 42673c383a | |||
| 9aeac45198 | |||
| d9a152b772 | |||
| cd9ea5697b | |||
| 551ceef0e1 | |||
| b81a1e7c9c | |||
| 0355ec6b21 | |||
| 076b15d71f | |||
| d35daa0f72 | |||
| d138c5bff2 | |||
| 66d56396ca | |||
| 0c62c62a7a | |||
| 7d6c9244cf | |||
| 7f33c101c8 | |||
| 07ac8aca41 | |||
| de4db409ee | |||
| 712416f490 | |||
| 0d8c9d5cfb | |||
| 9547277931 | |||
| 02849956e8 | |||
| dcf5975334 | |||
| 747ed6c64d | |||
| e586e4d109 | |||
| be2a0f4a18 | |||
| a184d16f06 | |||
| f6facc7507 | |||
| 7d7ceec1d6 | |||
| 3f4dff462d | |||
| 36927b4371 | |||
| 290200a490 | |||
| 57ccc13e0c | |||
| ef29ee4804 | |||
| 732664a1ff | |||
| f2ef7454c2 | |||
| e4023cadce | |||
| 92b9af5d9e | |||
| 51cc9c541f | |||
| 6ad7baeb2c | |||
| 266a4214c5 | |||
| 67a479a2cd | |||
| 459aaea6e1 | |||
| 9b93542e99 | |||
| 0b9931a3a4 | |||
| bb4f72d1ec | |||
| e86ee052cb | |||
| c6efb5ee3b | |||
| efcba5ecae | |||
| 416a5173ae | |||
| cc9b3a08d0 | |||
| 857ca4d978 | |||
| 0135d23b16 | |||
| babb84a798 | |||
| e92aaa0891 | |||
| 939a9267c6 | |||
| ff8633231f | |||
| 4e1bbd76f9 | |||
| 570814cf6e | |||
| 47a4c6b58c | |||
| 4fa2a879d7 | |||
| cd60a4aca7 | |||
| b664982be3 | |||
| 485785e023 | |||
| 5389a93ec8 | |||
| 634cacd435 | |||
| 61bf7a28d2 | |||
| e172c486c3 | |||
| da7ddd43f5 | |||
| 98e5fb1542 | |||
| f99b037c60 | |||
| 5a1209c82d | |||
| 8ddab7f0cc | |||
| 6cd8d008eb | |||
| f4f1145424 | |||
| d7c121430e | |||
| e23704d694 | |||
| e4ddeb6033 | |||
| 4cdd98dbf5 | |||
| ce16dad88f | |||
| b59ed1b943 | |||
| ea31af5364 | |||
| ac2a95534e | |||
| 1a7450b9e9 | |||
| 5ef8280c31 | |||
| 15deeb19b0 | |||
| d13bbb7a04 | |||
| f2dc26a7b3 | |||
| 299e16bed1 | |||
| d864120353 | |||
| be03b3cdda | |||
| cfa3d817af | |||
| 2c716a88c4 | |||
| 89d2a896f1 | |||
| 56648638aa | |||
| 741a790660 | |||
| 684fa9b9c9 | |||
| 4e91039254 | |||
| 195e167502 | |||
| 01a50b06cb | |||
| 9b663b4c2b | |||
| 655426c322 | |||
| ae819ad44b | |||
| 50ad3f0f26 | |||
| 413a8be037 | |||
| da659817c5 | |||
| 6d37515e14 | |||
| ae27afaeb4 | |||
| 30f462288e | |||
| 4862505c5e | |||
| 4b0a8f81d5 | |||
| f889df8d50 | |||
| 836be74d13 | |||
| 7f24f0637b | |||
| 31d793fafb | |||
| be274478d0 | |||
| 5b8c91a877 | |||
| 95a4690e69 | |||
| 33694c8b47 | |||
| 14b7c591d0 | |||
| 72043d0657 | |||
| e0a0fcbde2 | |||
| 58dd8a29db | |||
| 1f83c00ebf | |||
| 02e1d01f29 | |||
| e0db3c87cf | |||
| 903299728f | |||
| c617ad6a04 | |||
| 814649e7a3 | |||
| d1b69142c4 | |||
| 2d1593f78e | |||
| d61f7af60c | |||
| 65140d1293 | |||
| 85299cd447 | |||
| 091df972f1 | |||
| 748040fb0b | |||
| df02ca764f | |||
| 6f64c26349 | |||
| 072355dc2c | |||
| 3ca2cad449 | |||
| 05bb81cd71 | |||
| fd9246358a | |||
| 42c4b32720 | |||
| 2757647211 | |||
| 45787dd8e4 | |||
| 38b797b42f | |||
| e8f6ebc154 | |||
| e715ce0625 | |||
| aceb586bef | |||
| 15f9b69b36 | |||
| 0aabb7d990 | |||
| b036767fc0 | |||
| b967cf6224 | |||
| 1a596fe84d | |||
| 64fa8d5282 | |||
| 99d2186c8c | |||
| 24f759e00e | |||
| 66731c9c66 | |||
| e5ec9cd676 | |||
| e7b63839c8 | |||
| 2511c378f2 | |||
| 3de37873dc | |||
| 12514a0311 | |||
| 8a9dd169e2 | |||
| 84046a060a | |||
| a27eec7752 | |||
| 4539a9a4ab | |||
| cffa098373 | |||
| c663a0d9c5 | |||
| 5b83b2375e | |||
| 98d72fae25 | |||
| 041ebacb8c | |||
| 4f2a22dd0e | |||
| 4acc0e9876 | |||
| 7be24776d5 | |||
| 485706a676 | |||
| ea7d963f20 | |||
| 613958a4b6 | |||
| 44023ea91d | |||
| ef7f7e35f8 | |||
| 613a50428b | |||
| 3091f61a26 | |||
| 5776b2596d | |||
| 430102c995 | |||
| 2a2bb4f1e1 | |||
| 205243e8b9 | |||
| d16ce643fd | |||
| e94eb8f668 | |||
| 357084e788 | |||
| 9a757acc88 | |||
| 3fb1c07eac | |||
| 6050b14087 | |||
| 58c1c1bb16 | |||
| b6f6ab17f9 | |||
| 7bcba437a0 | |||
| abf199bf61 | |||
| 9ea2db5c81 | |||
| 7a6fb4a807 | |||
| c3a75f5568 | |||
| c850c420fd | |||
| e045aaaf07 | |||
| 0cd40caf0c | |||
| f2bb9d65c3 | |||
| 4e05795642 | |||
| 1df52637e8 | |||
| b83362cc2e | |||
| 274052511c | |||
| 32bc1ec064 | |||
| 5fa62e02c6 | |||
| bf3c3367a6 | |||
| 9c05682605 | |||
| 8f090739d9 | |||
| 7971177c58 | |||
| 5707763758 | |||
| 35a786d765 | |||
| 12fe41e34d | |||
| 5ffd362b6e | |||
| a423fba2a8 | |||
| 41d0832fa5 | |||
| 5e7b0c9303 | |||
| 0c43e7986f | |||
| bc1d76a796 | |||
| 6b9f72d973 | |||
| d980cff663 | |||
| 7de69db707 | |||
| 5e34aee2d7 | |||
| 797719d8d5 | |||
| 6c3aa6ede5 | |||
| 18459ec1bc | |||
| e727788f42 | |||
| 3df7711e74 | |||
| c1f856fa8e | |||
| 8ffc7699d6 | |||
| a3eff53c69 | |||
| 56c12ad7c3 | |||
| 77a0f59cd3 | |||
| 94768530cc | |||
| 79a233eb78 | |||
| 183d800f4c | |||
| 191ad20436 | |||
| c0c68d1e46 | |||
| ac6968edf1 | |||
| e22e1d0e4a | |||
| 42e27dd14c | |||
| d817047c98 | |||
| e15cd6ae89 | |||
| 17e6063c5c | |||
| a8b2a2ff33 | |||
| 4b3eb09492 | |||
| d1c09cb21d | |||
| 1188793f8f | |||
| 09b8df1818 | |||
| 6192d32501 | |||
| a6a8d787e4 | |||
| e5c6d3f777 | |||
| 1bfa792ea9 | |||
| 8ef4f68215 | |||
| 493f5dcff2 | |||
| 2cf84e020f | |||
| e21bd9b4cb | |||
| ded94276a8 | |||
| a19ba3d530 | |||
| e0674ee7fe | |||
| 2481435829 | |||
| e48b565e18 | |||
| f6c2206b88 | |||
| 4717e01708 | |||
| 17861fc45d | |||
| a92c31168a | |||
| 940dcfb8c4 | |||
| 8dd9483572 | |||
| 4e7b33bde3 | |||
| 977780736f | |||
| aacfa1bd96 | |||
| 862ef57e0f | |||
| fa5499373a | |||
| f901f19714 | |||
| 6bde7c61b4 | |||
| 085c887b33 | |||
| 920c97af79 | |||
| f887c9f44b | |||
| 18ceebeffd | |||
| 854747574d | |||
| 7eb3b32b26 | |||
| 54dd11f511 | |||
| 1bc0635f8b | |||
| bea54b445e | |||
| bc735fee51 | |||
| 82175b5de9 | |||
| cefa3638cf | |||
| cbfd92a21d | |||
| 310e178206 | |||
| e0c4f7ccbf | |||
| 17904bccd0 | |||
| 5b2f40a454 | |||
| b1113c328a | |||
| 26d823bd81 | |||
| 5a5809bd95 | |||
| c225a15746 | |||
| edd62f3b4f | |||
| 73e4a69383 | |||
| 5e32e8868e | |||
| d430f2f52e | |||
| 51dbd133a4 | |||
| 4eb48660df | |||
| d66d8585a2 | |||
| 89661301b0 | |||
| 5d804987b9 | |||
| 892d3abf38 | |||
| 4a1a8c9fc5 | |||
| 18ede3ae1f | |||
| 9ed79e9e86 | |||
| 5a7555a6ec | |||
| 82d04d612b | |||
| 9f2eeb23ba | |||
| c84e79a46d | |||
| 337c2d0953 | |||
| 71189c8fb0 | |||
| 322f5933ad | |||
| 1e80dc71eb | |||
| 198a6c8e33 | |||
| 0fdb935c3d | |||
| dcafba8a2d | |||
| 131214151c | |||
| dd4e08e88d | |||
| b7b4067973 | |||
| 02478371f2 | |||
| 750972e7c6 | |||
| a9d7dc68a3 | |||
| 0a828aaed3 | |||
| f2bab9777d | |||
| 993bf897cf | |||
| df09d8c604 | |||
| 5904a1e7c0 | |||
| b826ed6b03 | |||
| 6eee72b336 | |||
| a2c5c577db | |||
| 6fa0ad5793 | |||
| 2891c8e29d | |||
| c3b3258194 | |||
| ef0aeb363b | |||
| c843661dfd | |||
| b2629b9bfa | |||
| ad2b3e6cc6 | |||
| cbe704333a | |||
| 45b45517c8 | |||
| 9d67cb4f34 | |||
| fe2eccfda4 | |||
| 81e54be0c1 | |||
| 2e49c33cc7 | |||
| e01e8dd4a2 | |||
| a1297b0402 | |||
| 53db88c630 | |||
| c99c13acd1 | |||
| 01a3dd1eb0 | |||
| 5383672d78 | |||
| 28f70d52ee | |||
| cfc1f8fbe4 | |||
| 1455e30350 | |||
| b46e9bb68a | |||
| 55a9c0738b | |||
| a72493f320 | |||
| 0d9d7b8e04 | |||
| 101db282c2 | |||
| ac78b2fa50 | |||
| e877eab033 | |||
| 68e760d13a | |||
| c323256812 | |||
| 26584cdbb4 | |||
| 64a5cedcdf | |||
| 40fedea408 | |||
| ffedfb7c0c | |||
| cc08ceb797 | |||
| 053e4f2fc8 | |||
| 727f58a24b | |||
| 99b6085235 | |||
| 006fb79967 | |||
| 5820e6ebe1 | |||
| 0776c35ddb | |||
| 471a37ef00 | |||
| 1242733735 | |||
| a6c9a7a944 | |||
| e782facdf3 | |||
| 077a41911b | |||
| cc60bc9dab | |||
| 425ca8aa3e | |||
| 73d2b7ed06 | |||
| 0048e2c8c4 | |||
| adee4ac8dd | |||
| 549adf6487 | |||
| b5502c5580 | |||
| 46bf669cdd | |||
| fa7a3e987d | |||
| b316b9c073 | |||
| 5b57c35522 | |||
| b9a07b104a | |||
| c7b379e53f | |||
| e0a3233ea3 | |||
| 1b588b14d8 | |||
| 2c839db941 | |||
| f9eaa8f930 | |||
| 59397fd8a5 | |||
| 6be582355c | |||
| ac73851f78 | |||
| 257897763d | |||
| 29d50994ae | |||
| b129ee3f04 | |||
| a47699bf6e | |||
| 66b8b591df | |||
| 7b47fe96dd | |||
| abc8e62d58 | |||
| 22e3fddf8d | |||
| ef36cf8446 | |||
| c5345239fc | |||
| a229960218 | |||
| 43180ef239 | |||
| e10240bd7c | |||
| a0ef6fce81 | |||
| 314bee2b4e | |||
| 050c93ee8d | |||
| feefcc98ef | |||
| 8f4ce91361 | |||
| f03f56ba4e | |||
| 457d552fa0 | |||
| be2fcf7f57 | |||
| ad6c4f5245 | |||
| db621e38d9 | |||
| 170af1ab00 | |||
| 31ef4e7b5a | |||
| f56f689970 | |||
| 17b73e7cb3 | |||
| 903f29a824 | |||
| 12f2193963 | |||
| 13ecbc263e | |||
| 7b9888c004 | |||
| 91cd4f96f0 | |||
| 95a44122dd | |||
| 2bd76dfdde | |||
| 26895294f9 | |||
| 4cd4559784 | |||
| 3fc96f2bd0 | |||
| 91dd9e2bf9 | |||
| 9c5642f141 | |||
| 00f0a743fc | |||
| 232751e3db | |||
| 1c600d5b20 | |||
| 9bc3b44a61 | |||
| 83729f18ad | |||
| fdb6e70322 | |||
| efaf3d591c | |||
| ef50eb6d6b | |||
| fb5a1f2306 | |||
| 9d4382d12e | |||
| 9ee76ecc93 | |||
| 0d2ca48d16 | |||
| f1857df5e2 | |||
| fc1dfb7ff9 | |||
| dc407bf293 | |||
| 4eb057227c | |||
| 9cd944fd77 | |||
| cd3593182a | |||
| 0f6820df9e | |||
| 0e158903c2 | |||
| 214d0513e5 | |||
| 75ca866991 | |||
| f22aa1b5d6 | |||
| 00d7ee93b2 | |||
| 537cbf983e | |||
| 4c54b1cfbc | |||
| e9ea58df64 | |||
| 65fff6feae | |||
| dbded5e753 | |||
| 3043645605 | |||
| 685bf56a30 | |||
| a4497ed547 | |||
| 28cb0bef25 | |||
| 114cdb2351 | |||
| a2bb8ad2f2 | |||
| 5a4de52900 | |||
| ff70e54e3e | |||
| fddc21670a | |||
| f02372cf58 | |||
| ab5f809074 | |||
| 121c1a0125 | |||
| 7678540270 | |||
| 248e6ff134 | |||
| 839ebd5b51 | |||
| fa64df6f91 | |||
| 0acd118c03 | |||
| 2b5244a54b | |||
| 2472dd5fac | |||
| 5899f676f7 | |||
| bb57dc1ae7 | |||
| 5a6c2c27df | |||
| 9f096fc63d | |||
| 4267aadd78 | |||
| ef77a54c7e | |||
| afb0af4afd | |||
| 9be92cc3d4 | |||
| 15aabfb4e7 | |||
| c83e899f1f | |||
| ebe90dcaa8 | |||
| 1c3ae11eba | |||
| b718aa88a2 | |||
| 6240c3d90b | |||
| c78f9d19f5 | |||
| 0ddacdd7e2 | |||
| f8486474aa | |||
| 906c54ce61 | |||
| f72d991c36 | |||
| 528f0e5434 | |||
| 88009ee278 | |||
| b192b7dd60 | |||
| 03d51bd18c | |||
| 5c6c932a75 | |||
| 92c3c136f9 | |||
| 5069436fd2 | |||
| 141ba2e951 | |||
| fae4dea37a | |||
| 860b22aba4 | |||
| 30dbccf99e | |||
| 9b2497bc57 | |||
| 0140808460 | |||
| 84aa30d9c2 | |||
| bc724deb5e | |||
| fbfc23211c | |||
| 3d4d3a763a | |||
| 046749566d | |||
| 3b1b8a8306 | |||
| 5e92747737 | |||
| 82ad7e2acc | |||
| 2d319d0856 | |||
| c060904f3f | |||
| a63c4b6441 | |||
| 9df860a202 | |||
| 2a1634fd6f | |||
| 2970864158 | |||
| 8e76d7a8ed | |||
| 50e5dd5bd0 | |||
| 7e2605188d | |||
| e5ae1cb85c | |||
| 1e78734f2c | |||
| d5fad88c56 | |||
| 35a81b868f | |||
| 84355c1ddd | |||
| 012121ea77 | |||
| 1e628b9edb | |||
| bfdeb6c4f5 | |||
| c42a9d6e50 | |||
| 083e32fd9e | |||
| 2a350fd3ab | |||
| 03928f1977 | |||
| a2771c7558 | |||
| 968e1db94d | |||
| bb0a3e09d6 | |||
| d109706ad3 | |||
| b958689264 | |||
| 859ea150ed | |||
| 91ca79b300 | |||
| 8210f40469 | |||
| 50ffaef33f | |||
| c25f88293b | |||
| 025cdd66c5 | |||
| 237f172ae5 | |||
| 4cd7e4e5a0 | |||
| e6688b9e86 | |||
| 65131c6f22 | |||
| 7667aca4c2 | |||
| 816791b9c1 | |||
| d6ea2220f7 | |||
| 69dd5db774 | |||
| adca9222ab | |||
| 7144aa6999 | |||
| fbad5f60eb | |||
| 266f592739 | |||
| 7c8bbcb3af | |||
| ba18e2bf6b | |||
| 5fefe97b87 | |||
| 5fba250a14 | |||
| 2606ad83ac | |||
| d450de8e0d | |||
| e4b0de0d4f | |||
| 2af4fd86cc | |||
| ddd171bc18 | |||
| 5ef4ef61f0 | |||
| 2679f92aa8 | |||
| cca438d77f | |||
| f2bc29e5c1 | |||
| fe7209e76d | |||
| 7c4a0453b7 | |||
| 97879834bc | |||
| 332535901f | |||
| e68e7a3224 | |||
| b935a8c652 | |||
| 65befd5ac4 | |||
| 78bdb5ef71 | |||
| 6eb7261dfd | |||
| 4f82be5bc0 | |||
| 3ac5772059 | |||
| eb723e47c2 | |||
| 8aa7f08350 | |||
| a54559d016 | |||
| 8e1f6abac5 | |||
| 7f3a2207a3 | |||
| 742c7913ea | |||
| 2d8ab726e2 | |||
| 702a296258 | |||
| c3c5414ce2 | |||
| ee3d375532 | |||
| e3f5c9175c | |||
| 7c24449a24 | |||
| 1c09846d3e | |||
| db94346863 | |||
| 3e6b9864d5 | |||
| 392c81ad69 | |||
| fe142c93fd | |||
| 578e7d634b | |||
| 6659a49869 | |||
| d9bc8b05e1 | |||
| 571405597b | |||
| 1441ce7f5f | |||
| 071a587755 | |||
| c1db01425e | |||
| 7bfd48e2ab | |||
| e80309af32 | |||
| fa1814ff54 | |||
| d7b8a2684a | |||
| 8559cd299d | |||
| b2d3c7d1fd | |||
| 5100e0e8b7 | |||
| 8acb921ee3 | |||
| 9ee0f04e58 | |||
| fc88001a8c | |||
| fab6c4048d | |||
| 7b32791006 | |||
| aa04948319 | |||
| 5903eb8ceb | |||
| 211e62a8e7 | |||
| 64a9b06e64 | |||
| 6d81aa4462 | |||
| 406b6bf410 | |||
| 4e41d8aff8 | |||
| 017c6e4e1f | |||
| 7d3233c7ad | |||
| 3e2662582c | |||
| c94dee8191 | |||
| ab2ef13d99 | |||
| fac9ab5c01 | |||
| 420e0b9ca4 | |||
| ea0340db8e | |||
| 0bd1ea07a7 | |||
| c8c28770fb | |||
| 0dfd968824 | |||
| b84ca9cc13 | |||
| e5734425ba | |||
| 2274a10cfd | |||
| 302e234bfe | |||
| 2b942bf06b | |||
| 522f6cb455 | |||
| a757fbd37d | |||
| 33567ef338 | |||
| b2a15c259e | |||
| d12409b118 | |||
| 8aed1eca13 | |||
| f389688caa | |||
| 7003c284d0 | |||
| facb2949c3 | |||
| 1b1355a595 | |||
| d76e4c8aed | |||
| cc1224e032 | |||
| 09de115670 | |||
| 23110b5d19 | |||
| a326f4a989 | |||
| d21b9d58e1 | |||
| 9d362c3738 | |||
| b06580d343 | |||
| a4240bdfb7 | |||
| 1eab1cb367 | |||
| 2e38416e12 | |||
| 034a3f1808 | |||
| 531519e8f2 | |||
| 6a80091fef | |||
| 742653ce75 | |||
| a8c3d07d9f | |||
| df1ef5db78 | |||
| 4b15ab5e99 | |||
| cdc97e9b2b | |||
| bd84b97614 | |||
| d7eb1cca07 | |||
| 5856f74d83 | |||
| 563509c4a6 | |||
| f3983cd6b7 | |||
| d0753fa527 | |||
| 524e3bedc7 | |||
| 30b60754e3 | |||
| 88c49dc2cb | |||
| bb3dcc2622 | |||
| 5cca0640d9 | |||
| fb48ceeeee | |||
| 90f4bba8fd | |||
| 802187abc4 | |||
| 49dd17c047 | |||
| a3b94c24de | |||
| ac4485dc84 | |||
| 4d1e25cdab | |||
| ec00e99477 | |||
| a73dca3e50 | |||
| ed71d2b2ac | |||
| 3911c2e0a2 | |||
| 1b6765db50 | |||
| 345fb69521 | |||
| 83a6abc70f | |||
| cfef726205 | |||
| de0f9e728c | |||
| d9754a532b | |||
| dc51023c61 | |||
| 87ce5c5419 | |||
| c4fc9f9618 | |||
| 8d7aa5db83 | |||
| 9c70fe3be8 | |||
| 78027d2ec6 | |||
| d4e4b9addf | |||
| b2acd22f58 | |||
| ae5ecb5bfa | |||
| 6f1340ce36 | |||
| 473fdba14f | |||
| 93a01a1aaf | |||
| 7c51ff4707 | |||
| bb6883213f | |||
| 54395b39a6 | |||
| 6deb817fd0 | |||
| 482e093331 | |||
| 042f903157 | |||
| c423ad4830 | |||
| 958b109a12 | |||
| 113fffdd69 | |||
| 4aaf09fded | |||
| 2f3df76f37 | |||
| cf7706b16d | |||
| 36963c05a2 | |||
| 48d840a1b8 | |||
| e3ebc908bb | |||
| 9ed8d8c113 | |||
| 9eab5daf19 | |||
| 6a24b595f0 | |||
| 150f237f13 | |||
| 17233084f1 | |||
| 41f2138b39 | |||
| 6376b8aaa6 | |||
| 58362ad143 | |||
| d72d23c2eb | |||
| 7702c5bfde | |||
| 20f2a6c003 | |||
| 0d4c1c47d5 | |||
| 4d32733790 | |||
| 0e58b6e95b | |||
| 19bfc48dca | |||
| ae0cc5a4b6 | |||
| ba74e0beb2 | |||
| e5ca4e788e | |||
| 1c7f034135 | |||
| 4c78ce6e3f | |||
| 7803d557b3 | |||
| 204fea395c | |||
| bd13de2b39 | |||
| d0f649b328 | |||
| 04e42d2175 | |||
| ffc88eaaa7 | |||
| 4b4cc5ebb9 | |||
| 0e6cddb547 | |||
| a69aec9070 | |||
| d2bd37962e | |||
| eb6763b0fd | |||
| d330afdd36 | |||
| 5db4bbc186 | |||
| e00f2666ff | |||
| 0238cdd5ec | |||
| 2c34d96b9d | |||
| 65b3630f6d | |||
| 54b629561e | |||
| 285ad36e7d | |||
| 5adde275fc | |||
| a3fa10d820 | |||
| acf47f3907 | |||
| b4d5335e43 | |||
| 39fb842e9b | |||
| 7a5d86b44d | |||
| 397e11e124 | |||
| f4314c318e | |||
| 9bb5536163 | |||
| 2344701f22 | |||
| 3bb909ba4f | |||
| 8ae0bd148b | |||
| 72251b880a | |||
| fefde4c290 | |||
| 3b2bae6128 | |||
| ae559b57de | |||
| 6135085d61 | |||
| 40bdc76af1 | |||
| d4f982a9cf | |||
| 813841bb68 | |||
| 930e63e6b9 | |||
| ce40d139e7 | |||
| 8368e11827 | |||
| e6b4662ec2 | |||
| 28f83d3d32 | |||
| 3e33d66ab4 | |||
| 13248d6736 | |||
| 8bd24724e7 | |||
| 80248e9a6e | |||
| 2734903886 | |||
| 2451b40d3e | |||
| 9fb6227461 | |||
| a2b322a31b | |||
| 69e1628a0d | |||
| 6307af1096 | |||
| 6e4e1abf1e | |||
| 2c15aad0e7 | |||
| 152c472bc2 | |||
| 8f6f17c341 | |||
| f2fe084988 | |||
| f5ba665c59 | |||
| 9cc5d7a691 | |||
| 94adc50487 | |||
| 1c93c2b000 | |||
| 6bad31f1be | |||
| 24e2c7926e | |||
| e3be3bac92 | |||
| c72c7dbe9a | |||
| 52c17dfce0 | |||
| c01b520ba6 | |||
| 796774efe4 | |||
| 0baa52afee | |||
| 4c6d9f5eff | |||
| 99dd889ff0 | |||
| b89d8d2740 | |||
| cc1e340585 | |||
| 3f2ae3ba62 | |||
| e622ece861 | |||
| 9f2e69a9e6 | |||
| 9b02f5220a | |||
| 2dd2144dcd | |||
| a5f53f158a | |||
| 2c7a257b5a | |||
| f579c724c6 | |||
| ab9d7ed509 | |||
| 9524263803 | |||
| c27ddb1d79 | |||
| ce640048b8 | |||
| e222d92fb5 | |||
| f1ed9b31b6 | |||
| da0669c739 | |||
| 5679972d8d | |||
| 0aca2f0501 | |||
| 0fb32b63e7 | |||
| b38a4610eb | |||
| 59285709a6 | |||
| a304ca8f5b | |||
| 333e5b27aa | |||
| 5f4293a803 | |||
| fe80881ec9 | |||
| e1418a2caa | |||
| 68247acab1 | |||
| 6d05512c2f | |||
| bf6d6a29c0 | |||
| 353286fd84 | |||
| c801df497f | |||
| 93a648ba15 | |||
| 826b9b1b1f | |||
| e661b160d8 | |||
| 8b6d00b193 | |||
| 093034acd1 | |||
| 6f968a125e | |||
| 5c9cee7fb9 | |||
| 7676837337 | |||
| c5145dc4f6 | |||
| 91e29e23a4 | |||
| 1e309e570d | |||
| 8362322d63 | |||
| aefa54f04b | |||
| 2c5e6b379f | |||
| c20f3f0595 | |||
| 5b17108f71 | |||
| 1fee3eb5f0 | |||
| bc4d84b60f | |||
| 6a67dceca7 | |||
| 9c8a68f742 | |||
| 2d67d31f90 | |||
| c1b52e0f35 | |||
| 55a7c01f73 | |||
| 6cf48f9479 | |||
| f9905f2bb5 | |||
| c07c74bf1b | |||
| 14536e9abc | |||
| 73c68e48a1 | |||
| a9aa021914 | |||
| 2ae32ed2c2 | |||
| 8ee3793f8f | |||
| 6f5b0c393e | |||
| a4152347e5 | |||
| bb2dad6d5e | |||
| 92b791eb08 | |||
| 8365ce9d29 | |||
| e141b8e098 | |||
| c7ce8cf943 | |||
| 788ade2db0 | |||
| a9f332fdd6 | |||
| c6f1ae9426 | |||
| b12c909fd6 | |||
| 1a62f22a5b | |||
| 5c2574da7c | |||
| 9fbdb9712b | |||
| 7bc42e6eaa | |||
| b6b1bc8813 | |||
| a62d2589bc | |||
| e4069bdb93 | |||
| 1e100ac0ec | |||
| 9d865e4ac6 | |||
| b3b1418e11 | |||
| 3ab32faccc | |||
| 2eb09efc81 | |||
| dd2dfbf58d | |||
| d549311210 | |||
| 8a91592839 | |||
| 4d962c5aa5 | |||
| d9bd3153ea | |||
| 4991e14dff | |||
| 5629020538 | |||
| 361742c4a0 | |||
| 4272ac16c7 | |||
| 6c08d5fd81 | |||
| 2a9c20bfa2 | |||
| 8dab319a7f | |||
| 5d01c9fff3 | |||
| 020b6bde68 | |||
| 036bc03ebf | |||
| 86e70ad55c | |||
| bdf23ef48f | |||
| 820befa1a0 | |||
| 0d5b93bd07 | |||
| dbafe01064 | |||
| 51d9f7ff12 | |||
| 4beeeb92ac | |||
| 662f1ed6b7 | |||
| 05703ec3d7 | |||
| bfab4a4952 | |||
| 9d25e17fcb | |||
| 4828ddcdd7 | |||
| d25a3909d1 | |||
| 695d333d2f | |||
| 5f28adec36 | |||
| 799e8214f8 | |||
| c893817e56 | |||
| 65785db659 | |||
| 85a7723b13 | |||
| ac827d3154 | |||
| 95b09aa5fe | |||
| 4e79b90863 | |||
| 306c02bcd4 | |||
| fc66a0715a | |||
| 9c7aecf0fd | |||
| 9f5a51e854 | |||
| a7f19e9e45 | |||
| 9b5862b61f | |||
| 176533e1a5 | |||
| c243637d44 | |||
| 7c52a6f9f6 | |||
| 446f8e7110 | |||
| 7db1cfa898 | |||
| 9a6aa01115 | |||
| 4a88e0255d | |||
| edc56949b7 | |||
| 63bc06d0fe | |||
| 9b58b66172 | |||
| 3517295e96 | |||
| c685876e6f | |||
| cb2c9c43a8 | |||
| 751a567e84 | |||
| 0a99bb9a7d | |||
| a2e7aec37f | |||
| 102e2d07d9 | |||
| 5400d22bc2 | |||
| 8d3fd21be5 | |||
| bb39ed136f | |||
| 363f6eba44 | |||
| 0ca305a1bf | |||
| 1d1e64b834 | |||
| 688e327f15 | |||
| 8c7ec0e7d9 | |||
| 84fef8dea3 | |||
| c1d2ad68b3 | |||
| a577605726 | |||
| 71444736ae | |||
| b7e41ec32c | |||
| 7fa09596b0 | |||
| 7316e6648f | |||
| e9d346ce4f | |||
| 4b91e709f7 | |||
| 7de89286da | |||
| 569a953b43 | |||
| 1e7f795c69 | |||
| d2ae383b83 | |||
| 8978112433 | |||
| 117eaea720 | |||
| 278e85357d | |||
| 60ec59fa4a | |||
| 0aa82ad020 | |||
| 7bd319ddc7 | |||
| 7ceb667486 | |||
| 80c4786afd | |||
| 2f741d3b24 | |||
| d2b65f0f91 | |||
| c226782f23 | |||
| 57a82ebcc0 | |||
| 416885a726 | |||
| 9b4d2d9172 | |||
| d4b2bf20bb | |||
| ce9a0555c5 | |||
| 5171250a9d | |||
| 80b629916a | |||
| ecaf0da228 | |||
| 8c0a905a9f | |||
| 5a0326f666 | |||
| 790a651ac1 | |||
| 6f93bd17f2 | |||
| 3419d66c4b | |||
| cabf684ec9 | |||
| 2b6e6ce28e | |||
| 32101189a2 | |||
| 600c081801 | |||
| 0899a9d49a | |||
| c56f4eabca | |||
| bfe89e0b12 | |||
| 6cb38cfa92 | |||
| 09bb0c9397 | |||
| fa47b0306d | |||
| 55429ad589 | |||
| 9592fb099f | |||
| 18ec6116ad | |||
| 9d0f306684 | |||
| 3eba8d690f | |||
| c0b59007ce | |||
| 3485ba2a5d | |||
| 43ecfc7484 | |||
| 5ba53e56c9 | |||
| af1d14ace6 | |||
| c02bf715c5 | |||
| 0c0e902b07 | |||
| 750b53d7aa | |||
| 1d807c095a | |||
| 69b5873bf9 | |||
| 60fc9b6417 | |||
| 0bc8944a08 | |||
| 33292f54e0 | |||
| fc215ef0b2 | |||
| 65c67427d4 | |||
| bc8142974f | |||
| fadb7a8f8f | |||
| e1bfe90833 | |||
| 042dc0b33f | |||
| 8ca535dbf0 | |||
| e20183e7a1 | |||
| df86ffb61e | |||
| bfcf133c91 | |||
| 24a377d3a8 | |||
| baf51bc68f | |||
| 5f4b585164 | |||
| 17a11187b0 | |||
| 7caf7976cf | |||
| 1a31792c14 | |||
| d56eb49e41 | |||
| a1236b5e16 | |||
| 8f278be0dc | |||
| f8ab71e7f0 | |||
| 9cca3a3ec1 | |||
| 97bcf2a438 | |||
| 85dd2e9f4f | |||
| 23d62da87f | |||
| b4d947fecd | |||
| 650c95af31 | |||
| 943116d495 | |||
| 644df7c16e | |||
| 638773b216 | |||
| 889e7914e2 | |||
| 68cc85f2b2 | |||
| c273ce576b | |||
| f8d57096a8 | |||
| d7542e87ae | |||
| b178210a31 | |||
| 3e6a23b0e1 | |||
| ee8d2afe58 | |||
| 11e102e137 | |||
| e06b62ecf2 | |||
| d178102f82 | |||
| e1dd5cce7d | |||
| 1edc1f35fb | |||
| 4df47be521 | |||
| 9cb88bca5a | |||
| fa8cc1d3f4 | |||
| 9ae8a7ca33 | |||
| f4da179140 | |||
| 13330658cb | |||
| 9f04e46166 | |||
| 1072ea3fb0 | |||
| ea9e8055a4 | |||
| 784abf2a30 | |||
| ed4a70deff | |||
| fef20d10a2 | |||
| 176dcdc7cc | |||
| 12ed05f846 | |||
| 5999f22f76 | |||
| c056fd2a06 | |||
| cb422f043e | |||
| 4ae89dc9f6 | |||
| 4f6f07db1d | |||
| cd981c7294 | |||
| 557d2967fa | |||
| a7a70636dd | |||
| 2215661f89 | |||
| a22b590b43 | |||
| 1b0b209662 | |||
| 2a2761c54f | |||
| 1c83d72f39 | |||
| fcea774b59 | |||
| da2ec21571 | |||
| ebb8d8a2f7 | |||
| 9706a9c768 | |||
| cee67a8d4e | |||
| 87650557fd | |||
| d3bf52f12f | |||
| 6b13a4849b | |||
| 8e380c0d9d | |||
| 0caf4bfcec | |||
| 9c3b978b50 | |||
| ab689a7792 | |||
| 846646d92d | |||
| 2eb2b89432 | |||
| 43441a8218 | |||
| 561a541fa1 | |||
| ffe9ecc141 | |||
| 77f7884604 | |||
| 0a203d1e22 | |||
| f4f4550483 | |||
| e87226a092 | |||
| 391a3ec9bd | |||
| dd5cd31ef5 | |||
| de92e804fe | |||
| 7725d9aaaf | |||
| bd3e25adea | |||
| 0b1d49af4b | |||
| 7efa9e351e | |||
| 0b0141954b | |||
| 82b531fbfb | |||
| 67fb626339 | |||
| 9044d5f05d | |||
| 47663aa1f1 | |||
| 63c0aab19c | |||
| 261216f5e4 | |||
| f88b799d67 | |||
| 9c48dd172c | |||
| 09ce105eee | |||
| 651aa895f8 | |||
| 0509e41198 | |||
| 1b40d6a53a | |||
| f9189d48d1 | |||
| 849874a247 | |||
| 3f6510bae7 | |||
| a585a26c39 | |||
| 9943966a86 | |||
| 3617e51c01 | |||
| c931032f08 | |||
| 37b286eaa4 | |||
| 619287c273 | |||
| aeb9b68298 | |||
| bae8f6315b | |||
| a6f70f8935 | |||
| acca6f4009 | |||
| 727fdd2391 | |||
| 1d174e00c0 | |||
| a5e3e2f5ba | |||
| da43c2d52f | |||
| 262f27748c | |||
| a29aef7e1c | |||
| 1671391195 | |||
| 28b0d59c61 | |||
| 86433cef25 | |||
| e96ccd5f71 | |||
| 50a087bb3d | |||
| 1ec049c52f | |||
| ec38805542 | |||
| 4c8517d075 | |||
| edf06da6ea | |||
| eb43a2040e | |||
| 9d0ecc7d3e | |||
| ad943c5e02 | |||
| bdb4fd0d25 | |||
| 2440e05457 | |||
| 1337c6c0d1 | |||
| 957689e07c | |||
| 3952d74f87 | |||
| 6dc4b81693 | |||
| 9cd953b7be | |||
| 631810dda2 | |||
| 8c12bc5506 | |||
| d4091a4826 | |||
| a7c269886b | |||
| f54593037b | |||
| 0415cf6a08 | |||
| 87c22d32b0 | |||
| 27dd15b403 | |||
| dd452c19ce | |||
| acc0846cf3 | |||
| 5a6738841f | |||
| bea451c9d6 | |||
| 676e904ec6 | |||
| 49aa5c61bc | |||
| a2272b852c | |||
| 1fa77630f9 | |||
| a841c4cc05 | |||
| 1874808e3b | |||
| 149b67916b | |||
| 7fb6f58162 | |||
| a309114a18 | |||
| 35cbde9530 | |||
| b9211b182a | |||
| 81ec499ae9 | |||
| f2e276eabd | |||
| f6dbaba1f8 | |||
| 65dcff052a | |||
| e3861567c7 | |||
| e89a20c725 | |||
| a8acc6bd28 | |||
| eb5efc735e | |||
| 737af527cd | |||
| 875d2b7e63 | |||
| bf1cb0e1bd | |||
| 2bfeb1b06c | |||
| 820e4302b7 | |||
| 84d761b418 | |||
| e5e27f2ac4 | |||
| efca9b18a8 | |||
| 607821ecbc | |||
| 7cc1b239d4 | |||
| efa8de34da | |||
| bcf45e3c5a | |||
| 0a3cd1d2ab | |||
| 3e621856c8 | |||
| 32e4d64ddb | |||
| 46e45ca84b | |||
| fcb13bd8ee | |||
| eacad9b453 | |||
| ed479e2a13 | |||
| 19937cb75d | |||
| a95093222c | |||
| 7b599d1882 | |||
| 4d501fd2f4 | |||
| c3d3053ded | |||
| 14d5fd3e11 | |||
| 9f79453334 | |||
| c7f1c881c0 | |||
| c39c032b4e | |||
| fa96c18308 | |||
| d90145a47f | |||
| 4871f86346 | |||
| 919eaf1e9a | |||
| 8a84ca16d1 | |||
| 12b4fdd692 | |||
| 3d8451d5d0 | |||
| cf88f28519 | |||
| 15d99eee46 | |||
| 6d68277db8 | |||
| 3e3b5557f7 | |||
| ba1a9d9f8e | |||
| 3e1a7953ec | |||
| 073fb2d717 | |||
| 7f33021184 | |||
| b396096721 | |||
| 0a5c6d832f | |||
| d279566114 | |||
| 2693cbb136 | |||
| f7a9be4292 | |||
| a926033b66 | |||
| dbcdd06b19 | |||
| ff5dab5c70 | |||
| 84b576418f | |||
| 253b124903 | |||
| 33dc5ddf79 | |||
| a456fa537c | |||
| 9e1fb93e08 | |||
| 5d24f702be | |||
| ca8e2c2986 | |||
| 2f0e5a45c5 | |||
| c4b28b0bc4 | |||
| 6cc4747965 | |||
| 91cd34b26a | |||
| e35a2f028c | |||
| 9cff2bd10f | |||
| 6d406498db | |||
| 939ae37baf | |||
| 4d6c8744e5 | |||
| e252d8b740 | |||
| 9b8d63e21b | |||
| 437fc04620 | |||
| 04dee090a3 | |||
| 245c6d24a1 | |||
| e92fd05f9f | |||
| 937f8e6919 | |||
| f489e6273e | |||
| 4f99bdbc87 | |||
| 1250b33220 | |||
| b57aee4595 | |||
| d9da51933d | |||
| 9fca93e7d8 | |||
| 854b2ed185 | |||
| cfac03bc40 | |||
| a3cb4a6ae8 | |||
| 2798fa4444 | |||
| 8bac0614f5 | |||
| 646280a6a9 | |||
| 208bdffdf7 | |||
| 9e7291903f | |||
| d56835fc00 | |||
| 1d5e717a80 | |||
| 2f44d9ae18 | |||
| 0627ab81d6 | |||
| 8167a398fc | |||
| 6291751014 | |||
| ee5ddaab52 | |||
| 207476be1f | |||
| b9b470c2ae | |||
| 52b6e8ef9d | |||
| 48c84bf74a | |||
| 5be30b3684 | |||
| 54a2b13825 | |||
| d44ddae3dc | |||
| 7bbc2459ba | |||
| 0cb77caa2a | |||
| 3f5f76458d | |||
| 835e07e8de | |||
| 3fc5e43abe | |||
| 9c8cb26bd6 | |||
| 540f4d2d0c | |||
| 51be255821 | |||
| 7d278fea25 | |||
| ca72d3b23a | |||
| e3b8f374e5 | |||
| 534cd3be1c | |||
| 78536de1b5 | |||
| edc67d9ec3 | |||
| 4dd12434b7 | |||
| f654bb2eda | |||
| 205f98cfeb | |||
| 69fa5bf464 | |||
| e7dc58ac6c | |||
| 2033299632 | |||
| 639d34d5d9 | |||
| 605181da32 | |||
| 183f631190 | |||
| 64c99b9871 | |||
| d29b0a27ff | |||
| aaa726e6dc | |||
| 05cc0c4644 | |||
| e1c0a92e60 | |||
| c770e4779a | |||
| c135122ca1 | |||
| 1d87df2afe | |||
| 8efc0ca0ea | |||
| 001d524ff7 | |||
| 5c5dce9dc3 | |||
| 293256c2ca | |||
| 4e027c1de3 | |||
| 6712a33164 | |||
| 98531143a6 | |||
| 71127ba308 | |||
| 0f6f571ccb | |||
| 9b6936a4fb | |||
| 8b78609412 | |||
| 4a31082f8c | |||
| 3643a69d8d | |||
| adbaa4aa89 | |||
| 0e025eda1b | |||
| 7c44bf8e94 | |||
| e6718f1113 | |||
| f3f6adb03a | |||
| 977827e453 | |||
| bcc9153991 | |||
| c04be14cd9 | |||
| de8f29751d | |||
| 12d58e4d08 | |||
| 3ae44185f4 | |||
| 1290f42f75 | |||
| 17b91dcad7 | |||
| 72da1642ee | |||
| 76d93b3a61 | |||
| 7be0ee9566 | |||
| 326e1f8da5 | |||
| e4e44ddd19 | |||
| 46bdde9265 | |||
| 09eba58927 | |||
| 0e884c78f5 | |||
| 2f44721086 | |||
| 6e08eebcbe | |||
| d9422d00ac | |||
| efc0501548 | |||
| bb07c60838 | |||
| 330ea05ca3 | |||
| 1f534b48a3 | |||
| aceae5eee3 | |||
| d4d66fd529 | |||
| b7686d6d37 | |||
| b97e397354 | |||
| ab8fbf171e | |||
| 2c0cfa24b0 | |||
| f28a76d470 | |||
| f3525c84a3 | |||
| abe9b54112 | |||
| b2aa59d893 | |||
| 9e9865afa7 | |||
| ecc439d4e8 | |||
| 452f0fc99e | |||
| 54f47845f6 | |||
| cb238cd6d9 | |||
| 897a9f4584 | |||
| 55f9b121de | |||
| 386f38af5e | |||
| 65cea430c2 | |||
| 4d38b508a3 | |||
| 5c774fd391 | |||
| f6d760e90f | |||
| c3ffa40bad | |||
| 5ce5d0e593 | |||
| b83f1efde8 | |||
| ca5f14c366 | |||
| 95a8b51fb4 | |||
| 2b64979730 | |||
| 508cb7db88 | |||
| e8d6d96883 | |||
| 9378a6e7bf | |||
| 1d609fc5c7 | |||
| 49d1e3dbaf | |||
| b0e9334852 | |||
| 95bd369959 | |||
| a433890097 | |||
| c9c3be517c | |||
| 89e122cd31 | |||
| 27c2a03ea8 | |||
| b56eb3a948 | |||
| fb1b0bfd88 | |||
| dd10167ec2 | |||
| 3138ad10ec | |||
| 080ca82605 | |||
| 0290de2360 | |||
| 9b330adc1d | |||
| f3ff1ae08b | |||
| 4f699af051 | |||
| 7ebc7259cb | |||
| 9d22edbdb8 | |||
| 7e95058cb5 | |||
| f33753e0cd | |||
| ac71e1d753 | |||
| 8151b6efd6 | |||
| 94de306c93 | |||
| 51f8ea26de | |||
| 29d9bb17cd | |||
| 30501a882d | |||
| f2f98e1d16 | |||
| cbf465eeea | |||
| 79c400e912 | |||
| cc4c49b5b0 | |||
| 96ea2c911d | |||
| 131b11680a | |||
| 3c6ab96283 | |||
| d2c4fa921a | |||
| dbb51a9328 | |||
| 55bfc3fa73 | |||
| d9c5182d1a | |||
| 899fcbf2da | |||
| 6e2c0d8706 | |||
| c4e599ce63 | |||
| 9cad9e4467 | |||
| 48019444ea | |||
| 76d31a7fbb | |||
| facb9d93c0 | |||
| 1d6bd46c5e | |||
| 8646dc1825 | |||
| 2992bdeed7 | |||
| c5601e6c88 | |||
| ef1d9a561c | |||
| 2d3b32c94a | |||
| 269378aa0d | |||
| 6889542801 | |||
| 8e6f1f1740 | |||
| b6ab1a992c | |||
| a5a267567c | |||
| f05f855c07 | |||
| bc5f773ba6 | |||
| 55308cc37c | |||
| 4d9db6edf0 | |||
| 38111a64e3 | |||
| bd8d3fca08 | |||
| 89ccaa3915 | |||
| 7c2cff7d99 | |||
| 788e15dbb6 | |||
| a0172d9d7e | |||
| bc1a7a1644 | |||
| c98234d3e6 | |||
| 45a94d23d5 | |||
| 351de5ee6a | |||
| 3559436d1e | |||
| 189f4c1637 | |||
| caead810e2 | |||
| ebdc5d9c9d | |||
| 4164059211 | |||
| bd27258c46 | |||
| ddf0605bc4 | |||
| 991dbe50e0 | |||
| 8050efb835 | |||
| 9355bc73a2 | |||
| acc2a6a353 | |||
| 09e83e7b8d | |||
| c0df8a3d80 | |||
| 33e890d225 | |||
| 750e5df962 | |||
| 74c65439fc | |||
| f290bd7170 | |||
| d398b749d4 | |||
| 2fd5a1574a | |||
| a7504f0629 | |||
| 3c35bb85ee | |||
| 6621edb04c | |||
| b0c722e297 | |||
| 47a6284274 | |||
| 150b8edb70 | |||
| aa5d3285eb | |||
| 993d6e3076 | |||
| 78ad9d8c2d | |||
| feff3ddce3 | |||
| 80fddad64d | |||
| 1e6dd0be02 | |||
| 22ecf4f1b6 | |||
| 5d21148657 | |||
| edb745ed92 | |||
| 61f4e0da6f | |||
| 767afa3106 | |||
| 16779359ee | |||
| 770653fafa | |||
| 0c021b6da7 | |||
| ec92b08f25 | |||
| 13e2353729 | |||
| 90d19a84ce | |||
| b4c0b95d8a | |||
| b7e8255066 | |||
| 5f8e6ad9ed | |||
| c8d253eb56 | |||
| 4814624cff | |||
| cc67f3d388 | |||
| f7c2a51c9f | |||
| 3db83e1159 | |||
| 3bb002796c | |||
| 45170bc53e | |||
| b79ff84c6f | |||
| 938c46fec9 | |||
| 8a13d94526 | |||
| 1e844d505a | |||
| a123a2c086 | |||
| 1eeeeb853e | |||
| 6e7224e306 | |||
| 9e064e2651 | |||
| 8d9dd17eac | |||
| cf1d3d3d2b | |||
| 9480ffcdc0 | |||
| 5db10add4a | |||
| fa66bf5d9d | |||
| f69da3ace1 | |||
| e01bfa05c3 | |||
| 231238c157 | |||
| 7edec099ab | |||
| 83eb8be064 | |||
| 7af30df494 | |||
| f026686fda | |||
| 35a50b9c6c | |||
| 010e2f951a | |||
| f7f86ad65a | |||
| 1e19f447d1 | |||
| 8cc378331d | |||
| 4721f68fd8 | |||
| 0d11c0a1f8 | |||
| 5076613a8f | |||
| c5a44daa65 | |||
| 520970b71f | |||
| ebfb08ee3f | |||
| 9e38b2cb90 | |||
| 71b1f00dc5 | |||
| 59d6830ab1 | |||
| 8779a3f211 | |||
| c10149baa0 | |||
| 4f87668780 | |||
| 63f33d1d8c | |||
| 734aa5a6fe | |||
| 371aef224d | |||
| 362e380ada | |||
| e995bd8c9a | |||
| 81b211dd1a | |||
| 0515fc94cb | |||
| 46ee070f0a | |||
| b17e3a6804 | |||
| 9160bee1af | |||
| 8e6018cfff | |||
| c08739b5a3 | |||
| 385a503d31 | |||
| ef286b0c15 | |||
| 53aba2d4b8 | |||
| f22da4ba3a | |||
| 23c2f12672 | |||
| 7fd53673ce | |||
| e64fd088b9 | |||
| 15672e7a09 | |||
| 2ea1d2c7b2 | |||
| 90d751f98d | |||
| 25a91c732c | |||
| 01995f5501 | |||
| 68abb3cf3d | |||
| 77cc323d0e | |||
| c7a9c03495 | |||
| f7850e3ed3 | |||
| 82125416a2 | |||
| 2c1e2155e3 | |||
| 2d30a53c3a | |||
| ccceeae29c | |||
| f22b98456f | |||
| e7f1bd692b | |||
| f82f7ab199 | |||
| 4d33b527b6 | |||
| 7bcc596308 | |||
| be2d4b080e | |||
| c96e5f5a9e | |||
| 3c23766674 | |||
| 718089fc11 | |||
| 8ab44dcb44 | |||
| 992522342c | |||
| 040898cdc3 | |||
| 343126ef22 | |||
| 05760d1eac | |||
| c10f73f1f7 | |||
| 7e0fa8e0cd | |||
| 6fe6218505 | |||
| 6059782de8 | |||
| 4844eea0ab | |||
| 8ecd62d3de | |||
| 4c610b4f58 | |||
| 1932c4ec44 | |||
| bd2e51ddca | |||
| ddcb7121c1 | |||
| f1f575fd5c | |||
| 99adb7cdc4 | |||
| 6b7ea97777 | |||
| 495b5758ec | |||
| ba56eb87b1 | |||
| 4258a3bbc9 | |||
| 4912331ddc | |||
| e87b7ecf5d | |||
| 23bce7bde6 | |||
| 926b664615 | |||
| fa8257c85b | |||
| abb9c88c23 | |||
| f89976cad5 | |||
| 0389778725 | |||
| 3c36285126 | |||
| 75054ee109 | |||
| 8447b1a42b | |||
| e5265a1c46 | |||
| 6e8ef8d0b0 | |||
| 75c081afc9 | |||
| 060fd9eaba | |||
| 63e5a60344 | |||
| 75dc1d82c1 | |||
| a5e048eb5f | |||
| 65bc1d5eb8 | |||
| bfa64705b5 | |||
| 17aea8d7d4 | |||
| a6a01fd7f2 | |||
| 41a9e91b4c | |||
| e2c1e11f95 | |||
| c2966817ce | |||
| 16958413bb | |||
| c0a0913d4b | |||
| 6d47810782 | |||
| 7a9ea2e546 | |||
| 7881b2dee4 | |||
| 5f223ef049 | |||
| e57942b374 | |||
| f18e6f078c | |||
| f667cbc2a2 | |||
| 07e65c14a9 | |||
| 0b6d04485e | |||
| 36401a063d | |||
| 849e7370d1 | |||
| f01dca0895 | |||
| 55137b2aa3 | |||
| 22540921b3 | |||
| 6174097a07 | |||
| 52de11b1fe | |||
| 5a646179ad | |||
| 33ae93e050 | |||
| f3d859159d | |||
| 4fb01e68f7 | |||
| 2812a247aa | |||
| 2b46e765c4 | |||
| c7f911cae2 | |||
| 9f0548c03d | |||
| c578df06a3 | |||
| 8ed3cf9c97 | |||
| 2438f565e9 | |||
| 8230c72ec6 | |||
| d716037caa | |||
| 855a4ddb2c | |||
| 74be9fac18 | |||
| e9fba5a166 | |||
| 0a92df691b | |||
| e513cd10ed | |||
| b702d98700 | |||
| 99f1d9d0ed | |||
| 707b08c585 | |||
| f44c19868c | |||
| 13ab139afc | |||
| cacb2f142b | |||
| 11f0317e92 | |||
| 9a667c8803 | |||
| c1cce17934 | |||
| 5a92d7de0d | |||
| 53bf378868 | |||
| cd7c45c00c | |||
| f13a5ad82e | |||
| 2e9be609c8 | |||
| 2f2f6e1ffe | |||
| f3bd2b67f7 | |||
| 645cecdffb | |||
| 22e9965629 | |||
| 24ea9f9245 | |||
| 9dbde6e8f1 | |||
| fe0b34544d | |||
| 5e489d59b4 | |||
| 61f49574a9 | |||
| 2fabcb62a8 | |||
| 3bc3b652c1 | |||
| 042a6f12f5 | |||
| 5acce82e63 | |||
| 4732bf46ad | |||
| 5bed5a1532 | |||
| 5b7576430f | |||
| 356f4cd701 | |||
| c444630d1e | |||
| 8e40cded42 | |||
| 0e52d467d3 | |||
| 6665d62e7e | |||
| 5bdf1a71b8 | |||
| a34ca0ff4b | |||
| 7f0163d958 | |||
| 31f19b0eee | |||
| 93d0760898 | |||
| 4863e7a6ae | |||
| a161b44cc7 | |||
| 7072244420 | |||
| f68b66e606 | |||
| 4e7c6c1fb4 | |||
| d8a7e36478 | |||
| 8971ad8445 | |||
| 270af8accb | |||
| b0ef63fc9d | |||
| 6e1f8c3cfc | |||
| e58d7e8dda | |||
| 3a3384cf06 | |||
| ef2a9f6fd1 | |||
| 63f756f731 | |||
| bb1c27c36a | |||
| 87cd0703c0 | |||
| 6317d9de53 | |||
| 7acf16fdba | |||
| a52b454d3e | |||
| 816e075c52 | |||
| 9882b361a8 | |||
| 4415dcf1c1 | |||
| 42fd583bfd | |||
| c70bc7c96a | |||
| 02bd780a33 | |||
| 24a2192ce2 | |||
| d8ef8a1f5d | |||
| 745a913cfb | |||
| 13dba407a2 | |||
| 34e7c5f809 | |||
| d570624caa | |||
| f18312419b | |||
| 89f869dd44 | |||
| 20b64507b1 | |||
| 7443246e05 | |||
| f9e7823c14 | |||
| 52943b283c | |||
| 36403fdc08 | |||
| 0317f6812e | |||
| 5169137069 | |||
| 7d9bccf912 | |||
| 14f56ea18f | |||
| 1736d271d2 | |||
| 19755ad233 | |||
| cfdd043e4e | |||
| 78917ed5cb | |||
| 88684ca00a | |||
| 784983806a | |||
| cdb3b94e22 | |||
| 83dcc4a5e0 | |||
| a6c0b281a3 | |||
| 3120f24553 | |||
| ac9be6134b | |||
| 4c1b4f7858 | |||
| 1e45bf93d8 | |||
| e8dd3979b6 | |||
| 374ee4c0ea | |||
| 95411aff77 | |||
| 1999ef95c1 | |||
| b15075fdfe | |||
| 4d2b244319 | |||
| 4c3af63076 | |||
| 91bbff6ced | |||
| 26aab44ec8 | |||
| 2e10ce421b | |||
| 8eda69b11e | |||
| 7d7b242968 | |||
| 202419202f | |||
| 55078beed1 | |||
| d9f4e6eaa6 | |||
| 2ba0913bea | |||
| 8f2dcf21ff | |||
| 01b06e0745 | |||
| 665b5960c8 | |||
| eb6a7a4728 | |||
| 7df53ff55e | |||
| 8021f39710 | |||
| f2af08270b | |||
| c2f028848c | |||
| d9c7224861 | |||
| f59a1ada88 | |||
| 705ab1d33f | |||
| c07c4d7217 | |||
| b867b2a0bc | |||
| 872d674182 | |||
| 4682abafdf | |||
| b7d194cf52 | |||
| edf2366296 | |||
| 22af5be71f | |||
| f662ff8051 | |||
| 8c51121b3b | |||
| e9a0805801 | |||
| afadbc6621 | |||
| ca546fc30b | |||
| 7c7c168c3d | |||
| 16f0bb96db | |||
| 33a899d32e | |||
| f3a208f02f | |||
| 81fd3d06bb | |||
| 9227139cf8 | |||
| f2190e50b2 | |||
| c4537b4753 | |||
| 167d58490b | |||
| d36aceb9f1 | |||
| eb31922124 | |||
| bec9f5a847 | |||
| 506552c3a9 | |||
| 2bacc77224 | |||
| bc53f265af | |||
| 344f232c36 | |||
| 27b677b0c0 | |||
| a5a0e381bd | |||
| d528d7f5ab | |||
| 821c71bd8d | |||
| 604a10400d | |||
| 9219471f67 | |||
| fe5d2e5685 | |||
| 0a89daa513 | |||
| d6e6ddf996 | |||
| 5dbda8aedc | |||
| 134e4cf28f | |||
| 56a85abef7 | |||
| 80c6ceaf26 | |||
| a10f428715 | |||
| 597f7468e9 | |||
| 5db8851213 | |||
| 1d53d760d8 | |||
| 922e720d63 | |||
| 50018773b7 | |||
| df99036d41 | |||
| ae0fa888f0 | |||
| 18892fb66d | |||
| 5f2be10563 | |||
| a5a88222a6 | |||
| 4facdd5c9e | |||
| 76bc9bd385 | |||
| 364452f3bb | |||
| 4996755f11 | |||
| e33230a88f | |||
| 951ce46932 | |||
| 795c7395e6 | |||
| 27cf47bcd3 | |||
| 58a25c6f61 | |||
| 2d754f80b1 | |||
| f4e8fbe767 | |||
| 458318d374 | |||
| e3f54e1353 | |||
| 4374996073 | |||
| 87295ef1fe | |||
| 81d4082b6a | |||
| d7e19bc3f3 | |||
| 34ef0ea792 | |||
| 2804834540 | |||
| add7dd5a45 | |||
| e40894ca45 | |||
| 28825f5395 | |||
| 6ca5141020 | |||
| fe4f8e1810 | |||
| 671157cb70 | |||
| f775479c3f | |||
| 64bb72842e | |||
| e1d4ba9d23 | |||
| a1edd83add | |||
| f7d6883405 | |||
| 8448a70646 | |||
| 4018bfa899 | |||
| 3cc9ce74e1 | |||
| eac60d845f | |||
| 835c045c92 | |||
| be15f85eae | |||
| 3e27ea0259 | |||
| 6abe660287 | |||
| a06ca31530 | |||
| 890865251b | |||
| 6af90cafee | |||
| 2e2363bb41 | |||
| 108ced2b0b | |||
| fcba650348 | |||
| 1b8a082942 | |||
| 40570cdb03 | |||
| 10451864e6 | |||
| 55e2646367 | |||
| c88839edb1 | |||
| 2a2cfc289c | |||
| 8bbeb186c2 | |||
| be4bf39719 | |||
| 459c69839a | |||
| a5407e57d9 | |||
| 5c749e7762 | |||
| b3fafc64f8 | |||
| c7b0763ab0 | |||
| 0cfdf60de5 | |||
| 096bff791d | |||
| 0cce858641 | |||
| bb45d8d578 | |||
| 7e43aa6b9d | |||
| 4ee7c82bf1 | |||
| 85caa40a3d | |||
| f4654bf446 | |||
| 94ed0bf9c9 | |||
| 22e3705d3e | |||
| 9b1cc6e9c7 | |||
| 9429c8ff83 | |||
| 056c6d4688 | |||
| 382356bc8d | |||
| 1deb3510f0 | |||
| dd7ae1b07a | |||
| 04a8755162 | |||
| 682f99a763 | |||
| 61282d6dab | |||
| ad540f7c25 | |||
| a4f191c1c6 | |||
| 43531c2680 | |||
| 635f5d36fd | |||
| 1becc4932c | |||
| e36dd06f22 | |||
| 8f2c62d444 | |||
| 21efde1a38 | |||
| d8b6466ed0 | |||
| d7b0228e9e | |||
| 9da1277b47 | |||
| a3fd0c9a4a | |||
| ad7375b44b | |||
| 05120b585d | |||
| 9e32d74c8c | |||
| 0e62510c6f | |||
| c492de4fa8 | |||
| 6308380541 | |||
| 2609db1aec | |||
| 6c54e73dbd | |||
| 21abe62633 | |||
| e30b2b0732 | |||
| dcb74ee9df | |||
| 82bf21e831 | |||
| 66355354fc | |||
| 4204125dce | |||
| e6aa9d3a46 | |||
| 9416cd1274 | |||
| 8b5ab846b2 | |||
| a15b93be90 | |||
| 38ee5f7d53 | |||
| 6f9bbbf416 | |||
| 143bc3d8e3 | |||
| ea75b1a936 | |||
| 0dde8c735e | |||
| 1ab7f00b91 | |||
| 3ef42bfbf0 | |||
| 05fec23457 | |||
| 7225e49aa0 | |||
| 14e9deb254 | |||
| f9569b387f | |||
| a0722ed51f | |||
| e9ace9b17a | |||
| 4791d10761 | |||
| c686b1c080 | |||
| 056d6ebbd9 | |||
| baa2cb68de | |||
| e4909b318b | |||
| f1b7cb37c6 | |||
| 734728fa9c | |||
| b373ace065 | |||
| bc7b5c8626 | |||
| f2b45622d6 | |||
| 77cb219057 | |||
| cf34d7bd56 | |||
| 5adc9be0d9 | |||
| 58b2efc900 | |||
| 28326606f5 | |||
| 91c98bbb60 | |||
| 63cd1128a7 | |||
| c0236d7dfa | |||
| d4051df5b6 | |||
| 88045417ff | |||
| 500efb5601 | |||
| 97fe8235da | |||
| e1164e935b | |||
| b26330aee1 | |||
| 2b083709b5 | |||
| 0ac45dc379 | |||
| 650916c22a | |||
| 2804183325 | |||
| 2dc2610621 | |||
| 1736e71e6b | |||
| 69ee5375b9 | |||
| 3ac0a66887 | |||
| 20e873a1fc | |||
| 142484d89c | |||
| 76a9f4ca14 | |||
| c4e5679d5c | |||
| b08d7c3c38 | |||
| 5092d8e6c5 | |||
| 74d625ff97 | |||
| f1119e28e8 | |||
| 3082c7f761 | |||
| 5f36614dd7 | |||
| 1dcc7a4887 | |||
| 41e9d35487 | |||
| 977c8b7ee3 | |||
| 939e6244ee | |||
| e764b2393d | |||
| 6384e75ed9 | |||
| 195cae6577 | |||
| c8cf46a5a7 | |||
| eba97277b2 | |||
| 4e19fbc5fb | |||
| 494b5bbae2 | |||
| 987ce709e5 | |||
| 35ad4d869f | |||
| 39d654e3f2 | |||
| 7fe9c641f4 | |||
| ee1414c010 | |||
| 8eb1b685a5 | |||
| 46768d6f91 | |||
| bb6fed3dc2 | |||
| 47e74d27bf | |||
| b830f9b96d | |||
| c85162a8a0 | |||
| ef4e128af7 | |||
| cce8ac5118 | |||
| cb7c3a9fa4 | |||
| b0f859cc91 | |||
| 6d4da529ee | |||
| 6c7e536eeb | |||
| 36c2648be8 | |||
| 419b58452f | |||
| b1835ea4e8 | |||
| a876b6133d | |||
| 03ff358da8 | |||
| 037f74c549 | |||
| a8caf4ad21 | |||
| 51d9fe5253 | |||
| 3218c89f17 | |||
| 02e467fb57 | |||
| ec994f3080 | |||
| 1181ab499c | |||
| 5424935fd9 | |||
| b9fbfb91bd | |||
| 62f66b4fec | |||
| eef9da9a41 | |||
| 7d32be3b6c | |||
| c2ad9f5fb9 | |||
| 4847fecdaa | |||
| f75383e0c5 | |||
| f683dccb6f | |||
| 6fb106b618 | |||
| 97956ad903 | |||
| 5d72a5b5ae | |||
| 1d7ded562c | |||
| 0d87b601cc | |||
| 33fbedffb8 | |||
| 2cfcbc82e1 | |||
| e1721cb1b6 | |||
| 1d264a6545 | |||
| 565e48f6f1 | |||
| 2b20c77bc0 | |||
| 1665d92136 | |||
| f128cb9f61 | |||
| 6d55b30b39 | |||
| 953ea55899 | |||
| 966c93af00 | |||
| 41a0b52939 | |||
| 8281d9cdd1 | |||
| b0ece3bd8f | |||
| 19a856549a | |||
| 65bd31bb65 | |||
| a3830f0820 | |||
| 5f8656eb41 | |||
| 141bee9c49 | |||
| aa44c0fb11 | |||
| 79e2d30849 | |||
| e8a9c7ac72 | |||
| 006054d13a | |||
| b39d653fe9 | |||
| d9e7d4249f | |||
| 34ad4ae166 | |||
| 69684f5023 | |||
| 2ed1854f0c | |||
| 09da0f7388 | |||
| 7f943c6b5f | |||
| ed3fc529ed | |||
| 2eb0511ef5 | |||
| 8bc1f457c7 | |||
| 77a727e1d7 | |||
| 16cc3c0fca | |||
| 96106ace92 | |||
| 13e528abb6 | |||
| 0d5dfe59b9 | |||
| 8fd88307f7 | |||
| 57244a9553 | |||
| fb8aac38dd | |||
| 8f953dabe5 | |||
| d63c2882fd | |||
| 952eb7df15 | |||
| dfc76ddb76 | |||
| b0cddc29e4 | |||
| dfc61cb273 | |||
| 05922e4f21 | |||
| 6cf4bf81e5 | |||
| ad43989944 | |||
| 31e7037e3e | |||
| 425d45e502 | |||
| 9ddb148fcb | |||
| e4d34abd7e | |||
| 16103c43eb | |||
| 7fad4b686c | |||
| cd00ac446b | |||
| e2906fba0b | |||
| acd5e72f6c | |||
| 8f1fd259d4 | |||
| d9041da426 | |||
| 269ddb04af | |||
| b1c2b9f4e0 | |||
| 7e9fe8ea98 | |||
| af81bf2bde | |||
| 55addaa8ea | |||
| 6ccc4d119f | |||
| c05a91cdc9 | |||
| 077d8b9f48 | |||
| 15a6680833 | |||
| 6c61704e60 | |||
| cfa0b99cd8 | |||
| c0bb8bef06 | |||
| 86f9d5c39d | |||
| 33f2ae5fc4 | |||
| ea1277d76c | |||
| ee89a06b3e | |||
| a31108e753 | |||
| 2bf9bc98a7 | |||
| d67975249c | |||
| d3a2bef9ba | |||
| b7f67e3162 | |||
| 1a20edc0b0 | |||
| f80ba1473e | |||
| 89a8203949 | |||
| fd6321e71b | |||
| 7dffd9d1ff | |||
| 51a156420d | |||
| c92323c681 | |||
| 10e03eef3b | |||
| e151055521 | |||
| 1f8408b622 | |||
| 98ddadb131 | |||
| a5ac12545a | |||
| e58384d815 | |||
| ab381dacfe | |||
| 9162fde14a | |||
| 6cf1714a07 | |||
| c402e17605 | |||
| 25746e9844 | |||
| a8a8dbeab8 | |||
| 6113df2b3e | |||
| 8f7363df41 | |||
| dafc79bf80 | |||
| 9ae537cafc | |||
| 162df6b250 | |||
| 12f28dfc95 | |||
| 5d7d8abbde | |||
| b960faec45 | |||
| 9a057b757d | |||
| 296c4b750b | |||
| 7ecc47e127 | |||
| d03180ff4d | |||
| c1c52b072e | |||
| 72be3803ec | |||
| 5cb4a8557d | |||
| 7787135549 | |||
| 56368500a3 | |||
| 846c6a579e | |||
| 573179060e | |||
| fda345577a | |||
| 8387710473 | |||
| 3af3fd1428 | |||
| c7c6e2866e | |||
| 7172ae0232 | |||
| 4eac97a7d8 | |||
| 352e4c088a | |||
| 4d5814fc43 | |||
| 6d13b91d37 | |||
| 0376c99b5a | |||
| 77d9e472b7 | |||
| 2911ebb5d7 | |||
| f4d01f56c6 | |||
| 878305fee3 | |||
| 0460a53f53 | |||
| e622f6aff2 | |||
| 9e96a30ea2 | |||
| d188fbdf5a | |||
| 06c16bf560 | |||
| 29ea9e3237 | |||
| b01add2925 | |||
| a98ad9577b | |||
| ef8351151d | |||
| f6bb3c848e | |||
| 3fd4cbbbfd | |||
| b102e0dbc5 | |||
| 1c0e8f77c8 | |||
| bebcb70b14 | |||
| 165602ae0a | |||
| a36e00efeb | |||
| bd4d273e1c | |||
| 216a928861 | |||
| a157c3f940 | |||
| 5a23459b23 | |||
| 538b282f43 | |||
| 86f51f1e4a | |||
| 622f76d5fb | |||
| 65e06b12ae | |||
| b714f7db69 | |||
| 1063922682 | |||
| 2c6168129a | |||
| 45465c1bd1 | |||
| 8acecc88f9 | |||
| 575349929b | |||
| 3913a89434 | |||
| 1bc8c9e3e2 | |||
| b4a0cca9c4 | |||
| 78b13ef4e1 | |||
| a49df101cd | |||
| 7ff4a00063 | |||
| 2636f8acf1 | |||
| 9042a885fa | |||
| ef837bd9c6 | |||
| 6a76725d64 | |||
| 697dbdc604 | |||
| 86f98f3710 | |||
| 470c696976 | |||
| e61bd174c8 | |||
| c71b9bc122 | |||
| c5339cbbe7 | |||
| 29020b0ac0 | |||
| 0a0530af0a | |||
| a5783ab860 | |||
| ae2de91b4c | |||
| ceecbef586 | |||
| 2fa558b25f | |||
| f465b478d6 | |||
| a4abac4916 | |||
| 9f9cb097d9 | |||
| 5ab64e31fd | |||
| ac6a8b9b74 | |||
| f43d252d08 | |||
| 185f9efb9c | |||
| 47d423036f | |||
| 7fae21f255 | |||
| 3fce835da0 | |||
| 0b62ccf941 | |||
| f7c5d7fc7f | |||
| e484685282 | |||
| 9c857705ff | |||
| 76f680de33 | |||
| 1181b6ae3a | |||
| 8a7f4ab156 | |||
| 99d43a7ddc | |||
| bd97d7d94e | |||
| 73235f1967 | |||
| 1ebc8092a6 | |||
| edd93c39a3 | |||
| 88c43d1772 | |||
| a0a8eb4700 | |||
| 28e5c33e81 | |||
| f24847576d | |||
| dfaf27e9e5 | |||
| 32d5b28423 | |||
| 0b8ca3313e | |||
| e6bb5e82a3 | |||
| a24b97b004 | |||
| 08eeff7f1c | |||
| 769f31e69a | |||
| cdf92b64d6 | |||
| 6d1ca028e7 | |||
| a228356399 | |||
| 3521f1b641 | |||
| 1dedf3d83b | |||
| da4c01c011 | |||
| 9cd445ad40 | |||
| ff4ef7e240 | |||
| 4de574ee86 | |||
| 0481b4025b | |||
| 9495b858fd | |||
| 5576adbd0b | |||
| b8da86bce8 | |||
| a926d3dadd | |||
| a95624ab19 | |||
| cf745422f3 | |||
| 10e042454c | |||
| 759be06ebc | |||
| aea37272ea | |||
| 2f17d37f7b | |||
| df8623c4e2 | |||
| 5c9766fb1b | |||
| a3d2e03425 | |||
| 717dae8f5d | |||
| 373dbde42c | |||
| 125af33941 | |||
| b43e36a79d | |||
| 145fccdf6e | |||
| f9c478f250 | |||
| 5da822fdc4 | |||
| 5abf1b5742 | |||
| 9ac3841342 | |||
| 1f315c5b8d | |||
| b9440587d0 | |||
| 835a971f89 | |||
| 0bba2092af | |||
| c3240218f8 | |||
| 9e392985b8 | |||
| a7d30dd1d5 | |||
| fa96d881e1 | |||
| 9ca9d6c4bd | |||
| 7ad66db491 | |||
| 1dbda3872b | |||
| 3619a46f52 | |||
| 6a93d166c5 | |||
| c84e62febe | |||
| 8ff21d6936 | |||
| 3b0012ec30 | |||
| 62a3f1693d | |||
| ed6796dde0 | |||
| 46721d7552 | |||
| a9a5a78e02 | |||
| 7c4431ceeb | |||
| 8cfdc8f27f | |||
| 691baf5c16 | |||
| 8669057681 | |||
| b439aedce5 | |||
| 2504e405a7 | |||
| 6426409bf9 | |||
| 9cf4ea5c91 | |||
| 86343abcf8 | |||
| d0fe2d2f75 | |||
| 49ef4fd266 | |||
| 929a57ceb8 | |||
| c6f94ed95a | |||
| 949ac459fc | |||
| 32fc6868aa | |||
| 82394cd70e | |||
| 4670a5d2e2 | |||
| 273d992493 | |||
| 1c71340719 | |||
| ed61c2ee22 | |||
| 363dede57c | |||
| b29c6add47 | |||
| 8d01e565c5 | |||
| 47e0fb95d5 | |||
| 23d346b291 | |||
| 105cdf6fe6 | |||
| 5135264d56 | |||
| c3ff1a3db3 | |||
| d62c1dedf3 | |||
| bd105a188f | |||
| 09affd3981 | |||
| 8e7e18e22d | |||
| e03fd80fd4 | |||
| adc3201dcf | |||
| 3a681e5b1a | |||
| c90ed0d424 | |||
| 418cbb420b | |||
| c948f0c287 | |||
| 285b45d19d | |||
| 783f1c8457 | |||
| daa7f12994 | |||
| e63e989d41 | |||
| 31921905a9 | |||
| 5572ab858e | |||
| 961ca0879d | |||
| 5d464494b6 | |||
| 4ca2513d00 | |||
| 15d69ed950 | |||
| 39bd2616c4 | |||
| 6302789c41 | |||
| 0ff31012c8 | |||
| 5c7b25c960 | |||
| 10102f2db9 | |||
| 6f5b5e4dc2 | |||
| 007c8a7b64 | |||
| 009ce9063e | |||
| 58a405bfa8 | |||
| 42214f17fc | |||
| b5f117e932 | |||
| b0f158047c | |||
| d5f7ca634d | |||
| aa6110c619 | |||
| a9660fe9fa | |||
| 0801245871 | |||
| 278fd3515f | |||
| 56588f3f7f | |||
| a5d01cb547 | |||
| fabf5d1ad5 | |||
| ebae3a4929 | |||
| 8e6640ed79 | |||
| e4c42bde89 | |||
| f7515edde9 | |||
| 2b0da75412 | |||
| 04c422c3af | |||
| 339ca74ff4 | |||
| 741a13379a | |||
| da907f35bd | |||
| 133531b6a0 | |||
| 5fa0f8dd7e | |||
| 7247413a48 | |||
| 591158adc5 | |||
| 5d83383105 | |||
| 5ad809f49e | |||
| 56a62bb4c2 | |||
| afb4a233be | |||
| c0aebe023c | |||
| 055c6a668e | |||
| 735c5fc7ed | |||
| c066fff971 | |||
| 89373ebcd6 | |||
| 51cf232691 | |||
| 3bfff2347f | |||
| 7d83604540 | |||
| f25571a0a9 | |||
| 05c7ba5f29 | |||
| dcf7772589 | |||
| 3806f9db07 | |||
| 0f14002b05 | |||
| 1bf53d8b89 | |||
| 8eb10a58ad | |||
| 9985378062 | |||
| 38ad5d457b | |||
| ebed433dde | |||
| 2b02f7e210 | |||
| 1434800982 | |||
| 327e33b827 | |||
| d2a053c1d7 | |||
| abe14e049a | |||
| 4b9db0c794 | |||
| b118cd8f27 | |||
| 83669964f5 | |||
| 9248fd6b28 | |||
| bb935967ac | |||
| b7e0f1f983 | |||
| 6ee6c007c5 | |||
| 9a507b54d7 | |||
| c88f516759 | |||
| 912b743a1e | |||
| d546424f18 | |||
| fe179fff42 | |||
| adf2ddb510 | |||
| f30c9020fa | |||
| 1b3073f3f9 | |||
| 615161ac9d | |||
| 02e06e7c6e | |||
| d15268eb22 | |||
| e48415d932 | |||
| e5fa341f39 | |||
| 234d734981 | |||
| d771ed9209 | |||
| 37d72cb8b3 | |||
| 1154f9601b | |||
| 322513f99b | |||
| 6e7ac60d4d | |||
| 405840607f | |||
| 8417e7ef65 | |||
| ac2fe44d8e | |||
| 3030d7f032 | |||
| dcf7138694 | |||
| 97df154b78 | |||
| d74034e08e | |||
| 674590e247 | |||
| d41cc7c3b6 | |||
| ab48800401 | |||
| ea456c5faa | |||
| 83d1442781 | |||
| 5888b0e06a | |||
| 3120d0bd7a | |||
| a7dcc2c9c6 | |||
| 17898cc747 | |||
| 7bebf062be | |||
| 048c3d5025 | |||
| 0adcdc6b4a | |||
| 19d7ad734b | |||
| 6c657dff37 | |||
| 78ccbeac3b | |||
| 2a0eae8975 | |||
| 28d25e7812 | |||
| fe795d49f3 | |||
| 9fad898ee3 | |||
| 9a42142ce7 | |||
| 9db8ed2dfc | |||
| 619a539f2e | |||
| ae8eb4a1f1 | |||
| 9a469e64da | |||
| f7d1613d62 | |||
| 80655bce50 | |||
| b3b0ba775c | |||
| 4713739d1a | |||
| 53b5de330e | |||
| fd4843c3a1 | |||
| 97d2b9e1f9 | |||
| 5896dadaad | |||
| 0ab60cb770 | |||
| 5b71e92776 | |||
| 211678c7d3 | |||
| d25793ed03 | |||
| 98cae011a5 | |||
| 59ae6f9c10 | |||
| 474d1669d9 | |||
| 563a1408ea | |||
| 168c08a6f6 | |||
| 82783072ef | |||
| 11972ef96c | |||
| 468ba21283 | |||
| 78b0cae892 | |||
| 866482a8e8 | |||
| c342310389 | |||
| 0eb028f0b5 | |||
| 4ffe4f2262 | |||
| 677549ec15 | |||
| 68d8e25bc4 | |||
| 4f007fdd44 | |||
| 54392941f3 | |||
| ebdad47f2d | |||
| cb4e36f591 | |||
| cd30efaaa1 | |||
| 7c234e0437 | |||
| d973c5d5c7 | |||
| a7f15a4e00 | |||
| 6b5484bf55 | |||
| ab38b709b2 | |||
| 4118038198 | |||
| 142154c0df | |||
| 07ae90d64d | |||
| 8a69fd09fc | |||
| c02f502bd8 | |||
| d5d6b8c303 | |||
| 5c592afebe | |||
| 8402a2b710 | |||
| fe152dfa63 | |||
| e695983d4d | |||
| a5ab2ba332 | |||
| c6e5a52104 | |||
| 1b4a879eda | |||
| c5aa493d24 | |||
| a88363e34c | |||
| 0f1261d0e3 | |||
| c41d11df9f | |||
| 1e680c7a8b | |||
| e981143ead | |||
| 3e2d5e0bdb | |||
| 1f19ed71aa | |||
| 4de6881c89 | |||
| 5baa82da8f | |||
| 48f610a216 | |||
| e4e58791a6 | |||
| 46c42ec249 | |||
| d068c1418e | |||
| 41db3a32f4 | |||
| b3a00becf3 | |||
| d1d8cd8482 | |||
| 1228907d59 | |||
| 57b54414d6 | |||
| 548a0c47af | |||
| 4934564b7b | |||
| 7348d14fef | |||
| 9cddb7ed9a | |||
| 8c84de3f73 | |||
| 96529a4c1c | |||
| c7a729fe06 | |||
| 23d404f681 | |||
| 887aeee2d4 | |||
| 622dbfda31 | |||
| 80cf3e833b | |||
| d305d25935 | |||
| 81502cfb6d | |||
| 5950a3fcc3 | |||
| 55f5e6d7aa | |||
| e2070e785c | |||
| 905d5abed6 | |||
| 211e06d04d | |||
| 7aaf9e9228 | |||
| a901e7177c | |||
| afc2bcfb28 | |||
| 8da204fbd8 | |||
| 5aa3212fe1 | |||
| 17d49510c4 | |||
| 4af8ae1470 | |||
| 3a5c660693 | |||
| 9e65100a06 | |||
| 399e47c548 | |||
| abdf8e696c | |||
| 4a2e217625 | |||
| 52d0280137 | |||
| 5be9765eb7 | |||
| cdb9488752 | |||
| 0388113870 | |||
| c6dfb4d4f8 | |||
| 4a40b58b63 | |||
| 407068a0bf | |||
| 165330ec68 | |||
| 6e7d08fbfb | |||
| 1ae77f56e5 | |||
| fccac04980 | |||
| 469f9c7ce5 | |||
| d6d37248f6 | |||
| cb1084b770 | |||
| e6d4459992 | |||
| 1afb5a4bc5 | |||
| c124f172b2 | |||
| dbd4a7c1d4 | |||
| a4d30ef206 | |||
| 0a616173ef | |||
| 597f210f85 | |||
| 24bd83feb0 | |||
| 3855786905 | |||
| 1f670a1ab2 | |||
| d97fda794c | |||
| c034d25299 | |||
| dd6152fe8a | |||
| 485fe572ff | |||
| 15bf5d9a4d | |||
| 08aa7c4e4c | |||
| 442c658be0 | |||
| 5aa8ce1c6b | |||
| ad8ece68c6 | |||
| 74525ba8f7 | |||
| 46d46afaaf | |||
| 13eb1150a5 | |||
| f98db6d21c | |||
| c695dfd92e | |||
| ffd78d76e1 | |||
| e479c41667 | |||
| 9f8c481992 | |||
| 3320d12994 | |||
| be6f522cf3 | |||
| b0b6871bbb | |||
| 59ae6217cd | |||
| 334cd7ad51 | |||
| 501c3680d9 | |||
| ebcc81c1ee | |||
| 6814372a89 | |||
| d5d14b7efc | |||
| 3a72686774 | |||
| aa73c5ed53 | |||
| cc0a385c22 | |||
| 0b8c9713e6 | |||
| e400a94ffb | |||
| 136ad3b0b5 | |||
| f9826104d8 | |||
| c0c97b76fb | |||
| a908e4d4b1 | |||
| e5c255200c | |||
| 00db4f5ed9 | |||
| 29ead3ff3e | |||
| 055074246e | |||
| 4bbe51fb4b | |||
| 841224372b | |||
| d1f0fa1a47 | |||
| 6fecf8bb01 | |||
| 6d44f02a38 | |||
| 1458e486d7 | |||
| dc29822e69 | |||
| dae7722da1 | |||
| 16d978dc58 | |||
| 5d3c154b45 | |||
| 00a8ef63b6 | |||
| 6ac437a3a5 | |||
| 33b24eba01 | |||
| 3a99c6e5f5 | |||
| 4c5d2839bd | |||
| 85b104bafa | |||
| 74e5d03a78 | |||
| cc43324ede | |||
| e4f9e1000d | |||
| 62829b0698 | |||
| 2551e990cb | |||
| 45c34319b5 | |||
| 75dcc566b3 | |||
| 4f1047e853 | |||
| 79f765c961 | |||
| eead2fad2c | |||
| 455c9e09ab | |||
| 4665c3565c | |||
| 7456b4b4ad | |||
| 32a6454065 | |||
| c52640c672 | |||
| d62ef17290 | |||
| 216af6a662 | |||
| 35d860427e | |||
| 9206574bae | |||
| 9c6f54131f | |||
| d67b95c593 | |||
| 2bf2f1b822 | |||
| 9ad94eccad | |||
| 6e8a900f25 | |||
| d9aa9e4480 | |||
| fe74818a37 | |||
| 7335126064 | |||
| 945dd71251 | |||
| 652aa29370 | |||
| 7034e2015e | |||
| 0a890ad871 | |||
| b52bb1124e | |||
| 41f33af51b | |||
| 6b4763c7da | |||
| be07889a45 | |||
| 1b3243c09c | |||
| fee1c9eccf | |||
| 084f6c31cb | |||
| 592bf76eb0 | |||
| 6f0aee1cc5 | |||
| 3575e20137 | |||
| f69f529258 | |||
| 3e7416ca7d | |||
| cf324c5d8c | |||
| 9da883a50c | |||
| ea3e03aaba | |||
| 8d9fdfeafc | |||
| b2a8285ecb | |||
| 162e8f7e51 | |||
| 6c658813cd | |||
| 0839ea385f | |||
| 68fa235412 | |||
| 417ce4b470 | |||
| 48deaa5f57 | |||
| e9f7b8bc0c | |||
| e31861af2e | |||
| 1af482d950 | |||
| dd2436925b | |||
| b92b69564b | |||
| a4fa163333 | |||
| 635d228c86 | |||
| 75725db6fb | |||
| 5cd8475143 | |||
| 5629f37939 | |||
| 08ec04d8b6 | |||
| c0b46f364a | |||
| 303d03d43c | |||
| 8c5f74e8bb | |||
| 94832262e3 | |||
| aefbfd52e9 | |||
| f3f0689bd4 | |||
| 5198d4c5fc | |||
| 123f2d3e4e | |||
| 3c750c3c92 | |||
| 17b29cd19f | |||
| cf1077bec4 | |||
| 4e2e4e95e0 | |||
| 61d64e7ae4 | |||
| 883797c495 | |||
| 0113971877 | |||
| 664b0c06a6 | |||
| bd4c75a98e | |||
| d35840409b | |||
| abaef9ba87 | |||
| b15d8bdd2e | |||
| 718997327a | |||
| fdfefbb94d | |||
| 2b865a55ac | |||
| 8138215597 | |||
| 7cc0c7a1cc | |||
| 50f561dbd2 | |||
| 4c647aaa19 | |||
| 48b1d616c5 | |||
| 693c37d6d6 | |||
| d525c04826 | |||
| c170edbdfc | |||
| 66e40155a9 | |||
| 59ad1a9b00 | |||
| a5b536e218 | |||
| 0e6c2e790d | |||
| 5761e73061 | |||
| 34c761e9db | |||
| 87e3813636 | |||
| 361ff0315c | |||
| 2bb227d058 | |||
| 99dc69e839 | |||
| d78fde8099 | |||
| 5d0c8956d6 | |||
| c9537af062 | |||
| dfb5b3a8ce | |||
| a177e44583 | |||
| 7ae03729f3 | |||
| 898ec21a25 | |||
| 6d7d8dec02 | |||
| ea7e2ec5ec | |||
| a5b8e2aa2f | |||
| 123333d9c2 | |||
| 0c4fa1d96a | |||
| e5805e8c69 | |||
| bf2d45a012 | |||
| a7122788b1 | |||
| 237c58f2b0 | |||
| efa23e4a1d | |||
| c109cee7ef | |||
| e111d39c54 | |||
| 66306464e1 | |||
| dd34ac1722 | |||
| 34cb222b33 | |||
| a0276f7e81 | |||
| d39ef156de | |||
| f464dc7fb8 | |||
| d29b27a5df | |||
| 5346ca9046 | |||
| 6d5b552bb7 | |||
| aadc6aa504 | |||
| e8c3dfa13e | |||
| 836d62f4aa | |||
| 9eea93cc6e | |||
| 308cb55b6b | |||
| 75ada78f8f | |||
| ecd86e3a12 | |||
| c1aa5eb717 | |||
| d2fed1198b | |||
| a9f9261dbd | |||
| 161e0d6e97 | |||
| 3efe511f42 | |||
| 5d04c2e50a | |||
| 7b26b7ea4c | |||
| 9d1063c6b2 | |||
| 5ff7632d32 | |||
| e6fb41504c | |||
| a800f731dd | |||
| f1a9fbb74e | |||
| cf81a73526 | |||
| 65036fffe8 | |||
| a69934a7e3 | |||
| 9400457bf2 | |||
| 5060329721 | |||
| 07ab1d60e8 | |||
| 7377a82e19 | |||
| f82e3ac808 | |||
| 1a6cd1de04 | |||
| 90e6f685b7 | |||
| 0fc825dac1 | |||
| dbb27efe3e | |||
| 2d3d2e783e | |||
| 6ae1defa35 | |||
| d55e77fb90 | |||
| 7fb9ae71e7 | |||
| 9419555149 | |||
| ab634f8beb | |||
| 9503b80d57 | |||
| bc870226e5 | |||
| 7e106ae011 | |||
| 958e00e231 | |||
| ab187d225d | |||
| 9f5711d41d | |||
| cdb2773127 | |||
| d12532ccc1 | |||
| 53e9f05a10 | |||
| 60e7ab95bc | |||
| ae552e2b46 | |||
| 145b52f343 | |||
| 57b8fac0d5 | |||
| 16a4a5ba46 | |||
| 3d37c83532 | |||
| b02fa701b8 | |||
| 37b7c82c64 | |||
| 1deb27df06 | |||
| 84ed3d5767 | |||
| fc909a3db2 | |||
| 2f7d4cd80d | |||
| 03ccbf3613 | |||
| 1868465319 | |||
| ff473e2fcc | |||
| a3c38eec86 | |||
| 2015c847e8 | |||
| 1b583ed984 | |||
| 11191c746a | |||
| abedd3c5bf | |||
| 501ba5135b | |||
| a76c98c348 | |||
| 9dcdc1a339 | |||
| 6d1f386203 | |||
| ff9bbf0a49 | |||
| 66e24c8d40 | |||
| 34f117c631 | |||
| 21f2f16889 | |||
| f6fa7c422d | |||
| 6903b84bb6 | |||
| 0978b8fb4f | |||
| d014583e88 | |||
| a747f51b9d | |||
| 8300885ab6 | |||
| b489eed4ef | |||
| 0b57771d76 | |||
| 8a32a8271c | |||
| c3e716dafd | |||
| 119a11eb8d | |||
| e464d14842 | |||
| 905f46359a | |||
| 8e7bf1f908 | |||
| 3a1524ae6d | |||
| 5c04befea3 | |||
| ae3584cdff | |||
| a60578c82c | |||
| 74558a500c | |||
| d963d8c8c1 | |||
| 853892c24f | |||
| 641f939e3d | |||
| af77504eaf | |||
| 62649d6468 | |||
| bb914e605e | |||
| 62ee88bbfa | |||
| 99c964bb4a | |||
| 09ceaef3e9 | |||
| a82900af55 | |||
| 5ef589f31a | |||
| cd719f134d | |||
| f69eb219b5 | |||
| 0ffe17ee3d | |||
| 4ac647a215 | |||
| 2534655bc8 | |||
| a9b7d56d0b | |||
| e9ca1eb538 | |||
| 0532800895 | |||
| c1ad999c25 | |||
| 4accd1264d | |||
| e1f3da3aa8 | |||
| 4bf9a7950b | |||
| 428d7ec94a | |||
| 6cc0017826 | |||
| 8a9131c3dc | |||
| aca1df634d | |||
| 053a3c1a53 | |||
| 468c315087 | |||
| b3d5fc149e | |||
| 277b7a4536 | |||
| 43886511b9 | |||
| 054ef87886 | |||
| 39c65d9e9a | |||
| b97bbbfa3d | |||
| ace6ba8096 | |||
| a2b87d84e9 | |||
| fd63a2209b | |||
| a26ec37f59 | |||
| 779ad93bcb | |||
| 1ec0219473 | |||
| 61a67892ac | |||
| 388d5954cb | |||
| 20977558cc | |||
| f6aafc1d6b | |||
| 9014325a7c | |||
| fc11856a28 | |||
| b0726b9733 | |||
| 4e4ea25e7f |
21
.agents/instructions/markdown-format.instructions.md
Normal file
21
.agents/instructions/markdown-format.instructions.md
Normal file
@ -0,0 +1,21 @@
|
||||
---
|
||||
name: "Standardize markdown document formatting"
|
||||
description: "Standardize the formatting of all markdown documents to keep structure clear, content readable, and the overall quality and user experience consistent. This document explains requirements for heading levels, paragraph formatting, code block usage, list formatting, and image and link insertion so authors can follow a unified style that is easier to read and maintain."
|
||||
applyTo: "*.{md,MD}"
|
||||
---
|
||||
|
||||
# Primary Formatting Requirements
|
||||
|
||||
- Keywords or specialized terms in the document must be formatted with inline code, for example `RuntimeClass`, `containerd`, `GPU`, and `AI`.
|
||||
- In Chinese text, do not add spaces around inline code.
|
||||
- For technical articles, review the generated content before finalizing it to ensure the material is technically accurate and contains no incorrect technical descriptions.
|
||||
- When the generated content is too large, split it into multiple tasks to avoid exceeding model output limits and causing the workflow to fail.
|
||||
|
||||
|
||||
# Detailed Content Requirements
|
||||
|
||||
- When documenting parameters or configuration items for a component or project, prefer tables when practical, and keep tables short enough to avoid horizontal scrolling during normal reading.
|
||||
- In Chinese paragraphs, use full-width punctuation rather than half-width punctuation, for example `,` instead of `,` and `;` instead of `;`.
|
||||
- Use `mermaid` for architecture diagrams, flowcharts, and similar visuals. If you need line breaks inside `mermaid`, use `<br/>` instead of `\n`.
|
||||
- If a code block is not a `mermaid` diagram and instead uses box-drawing characters such as `┌─`, `┐`, `┤`, or `│`, keep the content in English so the layout stays aligned.
|
||||
- Do not use `---` as a separator between paragraphs.
|
||||
152
.agents/prompts/opsx/apply.md
Normal file
152
.agents/prompts/opsx/apply.md
Normal file
@ -0,0 +1,152 @@
|
||||
---
|
||||
name: "OPSX: Apply"
|
||||
description: Implement tasks from an OpenSpec change (Experimental)
|
||||
category: Workflow
|
||||
tags: [workflow, artifacts, experimental]
|
||||
---
|
||||
|
||||
Implement tasks from an OpenSpec change.
|
||||
|
||||
**Input**: Optionally specify a change name (e.g., `/opsx:apply add-auth`). If omitted, check if it can be inferred from conversation context. If vague or ambiguous you MUST prompt for available changes.
|
||||
|
||||
**Steps**
|
||||
|
||||
1. **Select the change**
|
||||
|
||||
If a name is provided, use it. Otherwise:
|
||||
- Infer from conversation context if the user mentioned a change
|
||||
- Auto-select if only one active change exists
|
||||
- If ambiguous, run `openspec list --json` to get available changes and use the **AskUserQuestion tool** to let the user select
|
||||
|
||||
Always announce: "Using change: <name>" and how to override (e.g., `/opsx:apply <other>`).
|
||||
|
||||
2. **Check status to understand the schema**
|
||||
```bash
|
||||
openspec status --change "<name>" --json
|
||||
```
|
||||
Parse the JSON to understand:
|
||||
- `schemaName`: The workflow being used (e.g., "spec-driven")
|
||||
- Which artifact contains the tasks (typically "tasks" for spec-driven, check status for others)
|
||||
|
||||
3. **Get apply instructions**
|
||||
|
||||
```bash
|
||||
openspec instructions apply --change "<name>" --json
|
||||
```
|
||||
|
||||
This returns:
|
||||
- Context file paths (varies by schema)
|
||||
- Progress (total, complete, remaining)
|
||||
- Task list with status
|
||||
- Dynamic instruction based on current state
|
||||
|
||||
**Handle states:**
|
||||
- If `state: "blocked"` (missing artifacts): show message, suggest using `/opsx:continue`
|
||||
- If `state: "all_done"`: congratulate, suggest archive
|
||||
- Otherwise: proceed to implementation
|
||||
|
||||
4. **Read context files**
|
||||
|
||||
Read the files listed in `contextFiles` from the apply instructions output.
|
||||
The files depend on the schema being used:
|
||||
- **spec-driven**: proposal, specs, design, tasks
|
||||
- Other schemas: follow the contextFiles from CLI output
|
||||
|
||||
5. **Show current progress**
|
||||
|
||||
Display:
|
||||
- Schema being used
|
||||
- Progress: "N/M tasks complete"
|
||||
- Remaining tasks overview
|
||||
- Dynamic instruction from CLI
|
||||
|
||||
6. **Implement tasks (loop until done or blocked)**
|
||||
|
||||
For each pending task:
|
||||
- Show which task is being worked on
|
||||
- Make the code changes required
|
||||
- Keep changes minimal and focused
|
||||
- Mark task complete in the tasks file: `- [ ]` → `- [x]`
|
||||
- Continue to next task
|
||||
|
||||
**Pause if:**
|
||||
- Task is unclear → ask for clarification
|
||||
- Implementation reveals a design issue → suggest updating artifacts
|
||||
- Error or blocker encountered → report and wait for guidance
|
||||
- User interrupts
|
||||
|
||||
7. **On completion or pause, show status**
|
||||
|
||||
Display:
|
||||
- Tasks completed this session
|
||||
- Overall progress: "N/M tasks complete"
|
||||
- If all done: suggest archive
|
||||
- If paused: explain why and wait for guidance
|
||||
|
||||
**Output During Implementation**
|
||||
|
||||
```
|
||||
## Implementing: <change-name> (schema: <schema-name>)
|
||||
|
||||
Working on task 3/7: <task description>
|
||||
[...implementation happening...]
|
||||
✓ Task complete
|
||||
|
||||
Working on task 4/7: <task description>
|
||||
[...implementation happening...]
|
||||
✓ Task complete
|
||||
```
|
||||
|
||||
**Output On Completion**
|
||||
|
||||
```
|
||||
## Implementation Complete
|
||||
|
||||
**Change:** <change-name>
|
||||
**Schema:** <schema-name>
|
||||
**Progress:** 7/7 tasks complete ✓
|
||||
|
||||
### Completed This Session
|
||||
- [x] Task 1
|
||||
- [x] Task 2
|
||||
...
|
||||
|
||||
All tasks complete! You can archive this change with `/opsx:archive`.
|
||||
```
|
||||
|
||||
**Output On Pause (Issue Encountered)**
|
||||
|
||||
```
|
||||
## Implementation Paused
|
||||
|
||||
**Change:** <change-name>
|
||||
**Schema:** <schema-name>
|
||||
**Progress:** 4/7 tasks complete
|
||||
|
||||
### Issue Encountered
|
||||
<description of the issue>
|
||||
|
||||
**Options:**
|
||||
1. <option 1>
|
||||
2. <option 2>
|
||||
3. Other approach
|
||||
|
||||
What would you like to do?
|
||||
```
|
||||
|
||||
**Guardrails**
|
||||
- Keep going through tasks until done or blocked
|
||||
- Always read context files before starting (from the apply instructions output)
|
||||
- If task is ambiguous, pause and ask before implementing
|
||||
- If implementation reveals issues, pause and suggest artifact updates
|
||||
- Keep code changes minimal and scoped to each task
|
||||
- Update task checkbox immediately after completing each task
|
||||
- Pause on errors, blockers, or unclear requirements - don't guess
|
||||
- Use contextFiles from CLI output, don't assume specific file names
|
||||
|
||||
**Fluid Workflow Integration**
|
||||
|
||||
This skill supports the "actions on a change" model:
|
||||
|
||||
- **Can be invoked anytime**: Before all artifacts are done (if tasks exist), after partial implementation, interleaved with other actions
|
||||
- **Allows artifact updates**: If implementation reveals design issues, suggest updating artifacts - not phase-locked, work fluidly
|
||||
157
.agents/prompts/opsx/archive.md
Normal file
157
.agents/prompts/opsx/archive.md
Normal file
@ -0,0 +1,157 @@
|
||||
---
|
||||
name: "OPSX: Archive"
|
||||
description: Archive a completed change in the experimental workflow
|
||||
category: Workflow
|
||||
tags: [workflow, archive, experimental]
|
||||
---
|
||||
|
||||
Archive a completed change in the experimental workflow.
|
||||
|
||||
**Input**: Optionally specify a change name after `/opsx:archive` (e.g., `/opsx:archive add-auth`). If omitted, check if it can be inferred from conversation context. If vague or ambiguous you MUST prompt for available changes.
|
||||
|
||||
**Steps**
|
||||
|
||||
1. **If no change name provided, prompt for selection**
|
||||
|
||||
Run `openspec list --json` to get available changes. Use the **AskUserQuestion tool** to let the user select.
|
||||
|
||||
Show only active changes (not already archived).
|
||||
Include the schema used for each change if available.
|
||||
|
||||
**IMPORTANT**: Do NOT guess or auto-select a change. Always let the user choose.
|
||||
|
||||
2. **Check artifact completion status**
|
||||
|
||||
Run `openspec status --change "<name>" --json` to check artifact completion.
|
||||
|
||||
Parse the JSON to understand:
|
||||
- `schemaName`: The workflow being used
|
||||
- `artifacts`: List of artifacts with their status (`done` or other)
|
||||
|
||||
**If any artifacts are not `done`:**
|
||||
- Display warning listing incomplete artifacts
|
||||
- Prompt user for confirmation to continue
|
||||
- Proceed if user confirms
|
||||
|
||||
3. **Check task completion status**
|
||||
|
||||
Read the tasks file (typically `tasks.md`) to check for incomplete tasks.
|
||||
|
||||
Count tasks marked with `- [ ]` (incomplete) vs `- [x]` (complete).
|
||||
|
||||
**If incomplete tasks found:**
|
||||
- Display warning showing count of incomplete tasks
|
||||
- Prompt user for confirmation to continue
|
||||
- Proceed if user confirms
|
||||
|
||||
**If no tasks file exists:** Proceed without task-related warning.
|
||||
|
||||
4. **Assess delta spec sync state**
|
||||
|
||||
Check for delta specs at `openspec/changes/<name>/specs/`. If none exist, proceed without sync prompt.
|
||||
|
||||
**If delta specs exist:**
|
||||
- Compare each delta spec with its corresponding main spec at `openspec/specs/<capability>/spec.md`
|
||||
- Determine what changes would be applied (adds, modifications, removals, renames)
|
||||
- Show a combined summary before prompting
|
||||
|
||||
**Prompt options:**
|
||||
- If changes needed: "Sync now (recommended)", "Archive without syncing"
|
||||
- If already synced: "Archive now", "Sync anyway", "Cancel"
|
||||
|
||||
If user chooses sync, use Task tool (subagent_type: "general-purpose", prompt: "Use Skill tool to invoke openspec-sync-specs for change '<name>'. Delta spec analysis: <include the analyzed delta spec summary>"). Proceed to archive regardless of choice.
|
||||
|
||||
5. **Perform the archive**
|
||||
|
||||
Create the archive directory if it doesn't exist:
|
||||
```bash
|
||||
mkdir -p openspec/changes/archive
|
||||
```
|
||||
|
||||
Generate target name using current date: `YYYY-MM-DD-<change-name>`
|
||||
|
||||
**Check if target already exists:**
|
||||
- If yes: Fail with error, suggest renaming existing archive or using different date
|
||||
- If no: Move the change directory to archive
|
||||
|
||||
```bash
|
||||
mv openspec/changes/<name> openspec/changes/archive/YYYY-MM-DD-<name>
|
||||
```
|
||||
|
||||
6. **Display summary**
|
||||
|
||||
Show archive completion summary including:
|
||||
- Change name
|
||||
- Schema that was used
|
||||
- Archive location
|
||||
- Spec sync status (synced / sync skipped / no delta specs)
|
||||
- Note about any warnings (incomplete artifacts/tasks)
|
||||
|
||||
**Output On Success**
|
||||
|
||||
```
|
||||
## Archive Complete
|
||||
|
||||
**Change:** <change-name>
|
||||
**Schema:** <schema-name>
|
||||
**Archived to:** openspec/changes/archive/YYYY-MM-DD-<name>/
|
||||
**Specs:** ✓ Synced to main specs
|
||||
|
||||
All artifacts complete. All tasks complete.
|
||||
```
|
||||
|
||||
**Output On Success (No Delta Specs)**
|
||||
|
||||
```
|
||||
## Archive Complete
|
||||
|
||||
**Change:** <change-name>
|
||||
**Schema:** <schema-name>
|
||||
**Archived to:** openspec/changes/archive/YYYY-MM-DD-<name>/
|
||||
**Specs:** No delta specs
|
||||
|
||||
All artifacts complete. All tasks complete.
|
||||
```
|
||||
|
||||
**Output On Success With Warnings**
|
||||
|
||||
```
|
||||
## Archive Complete (with warnings)
|
||||
|
||||
**Change:** <change-name>
|
||||
**Schema:** <schema-name>
|
||||
**Archived to:** openspec/changes/archive/YYYY-MM-DD-<name>/
|
||||
**Specs:** Sync skipped (user chose to skip)
|
||||
|
||||
**Warnings:**
|
||||
- Archived with 2 incomplete artifacts
|
||||
- Archived with 3 incomplete tasks
|
||||
- Delta spec sync was skipped (user chose to skip)
|
||||
|
||||
Review the archive if this was not intentional.
|
||||
```
|
||||
|
||||
**Output On Error (Archive Exists)**
|
||||
|
||||
```
|
||||
## Archive Failed
|
||||
|
||||
**Change:** <change-name>
|
||||
**Target:** openspec/changes/archive/YYYY-MM-DD-<name>/
|
||||
|
||||
Target archive directory already exists.
|
||||
|
||||
**Options:**
|
||||
1. Rename the existing archive
|
||||
2. Delete the existing archive if it's a duplicate
|
||||
3. Wait until a different date to archive
|
||||
```
|
||||
|
||||
**Guardrails**
|
||||
- Always prompt for change selection if not provided
|
||||
- Use artifact graph (openspec status --json) for completion checking
|
||||
- Don't block archive on warnings - just inform and confirm
|
||||
- Preserve .openspec.yaml when moving to archive (it moves with the directory)
|
||||
- Show clear summary of what happened
|
||||
- If sync is requested, use the Skill tool to invoke `openspec-sync-specs` (agent-driven)
|
||||
- If delta specs exist, always run the sync assessment and show the combined summary before prompting
|
||||
173
.agents/prompts/opsx/explore.md
Normal file
173
.agents/prompts/opsx/explore.md
Normal file
@ -0,0 +1,173 @@
|
||||
---
|
||||
name: "OPSX: Explore"
|
||||
description: "Enter explore mode - think through ideas, investigate problems, clarify requirements"
|
||||
category: Workflow
|
||||
tags: [workflow, explore, experimental, thinking]
|
||||
---
|
||||
|
||||
Enter explore mode. Think deeply. Visualize freely. Follow the conversation wherever it goes.
|
||||
|
||||
**IMPORTANT: Explore mode is for thinking, not implementing.** You may read files, search code, and investigate the codebase, but you must NEVER write code or implement features. If the user asks you to implement something, remind them to exit explore mode first and create a change proposal. You MAY create OpenSpec artifacts (proposals, designs, specs) if the user asks—that's capturing thinking, not implementing.
|
||||
|
||||
**This is a stance, not a workflow.** There are no fixed steps, no required sequence, no mandatory outputs. You're a thinking partner helping the user explore.
|
||||
|
||||
**Input**: The argument after `/opsx:explore` is whatever the user wants to think about. Could be:
|
||||
- A vague idea: "real-time collaboration"
|
||||
- A specific problem: "the auth system is getting unwieldy"
|
||||
- A change name: "add-dark-mode" (to explore in context of that change)
|
||||
- A comparison: "postgres vs sqlite for this"
|
||||
- Nothing (just enter explore mode)
|
||||
|
||||
---
|
||||
|
||||
## The Stance
|
||||
|
||||
- **Curious, not prescriptive** - Ask questions that emerge naturally, don't follow a script
|
||||
- **Open threads, not interrogations** - Surface multiple interesting directions and let the user follow what resonates. Don't funnel them through a single path of questions.
|
||||
- **Visual** - Use ASCII diagrams liberally when they'd help clarify thinking
|
||||
- **Adaptive** - Follow interesting threads, pivot when new information emerges
|
||||
- **Patient** - Don't rush to conclusions, let the shape of the problem emerge
|
||||
- **Grounded** - Explore the actual codebase when relevant, don't just theorize
|
||||
|
||||
---
|
||||
|
||||
## What You Might Do
|
||||
|
||||
Depending on what the user brings, you might:
|
||||
|
||||
**Explore the problem space**
|
||||
- Ask clarifying questions that emerge from what they said
|
||||
- Challenge assumptions
|
||||
- Reframe the problem
|
||||
- Find analogies
|
||||
|
||||
**Investigate the codebase**
|
||||
- Map existing architecture relevant to the discussion
|
||||
- Find integration points
|
||||
- Identify patterns already in use
|
||||
- Surface hidden complexity
|
||||
|
||||
**Compare options**
|
||||
- Brainstorm multiple approaches
|
||||
- Build comparison tables
|
||||
- Sketch tradeoffs
|
||||
- Recommend a path (if asked)
|
||||
|
||||
**Visualize**
|
||||
```
|
||||
┌─────────────────────────────────────────┐
|
||||
│ Use ASCII diagrams liberally │
|
||||
├─────────────────────────────────────────┤
|
||||
│ │
|
||||
│ ┌────────┐ ┌────────┐ │
|
||||
│ │ State │────────▶│ State │ │
|
||||
│ │ A │ │ B │ │
|
||||
│ └────────┘ └────────┘ │
|
||||
│ │
|
||||
│ System diagrams, state machines, │
|
||||
│ data flows, architecture sketches, │
|
||||
│ dependency graphs, comparison tables │
|
||||
│ │
|
||||
└─────────────────────────────────────────┘
|
||||
```
|
||||
|
||||
**Surface risks and unknowns**
|
||||
- Identify what could go wrong
|
||||
- Find gaps in understanding
|
||||
- Suggest spikes or investigations
|
||||
|
||||
---
|
||||
|
||||
## OpenSpec Awareness
|
||||
|
||||
You have full context of the OpenSpec system. Use it naturally, don't force it.
|
||||
|
||||
### Check for context
|
||||
|
||||
At the start, quickly check what exists:
|
||||
```bash
|
||||
openspec list --json
|
||||
```
|
||||
|
||||
This tells you:
|
||||
- If there are active changes
|
||||
- Their names, schemas, and status
|
||||
- What the user might be working on
|
||||
|
||||
If the user mentioned a specific change name, read its artifacts for context.
|
||||
|
||||
### When no change exists
|
||||
|
||||
Think freely. When insights crystallize, you might offer:
|
||||
|
||||
- "This feels solid enough to start a change. Want me to create a proposal?"
|
||||
- Or keep exploring - no pressure to formalize
|
||||
|
||||
### When a change exists
|
||||
|
||||
If the user mentions a change or you detect one is relevant:
|
||||
|
||||
1. **Read existing artifacts for context**
|
||||
- `openspec/changes/<name>/proposal.md`
|
||||
- `openspec/changes/<name>/design.md`
|
||||
- `openspec/changes/<name>/tasks.md`
|
||||
- etc.
|
||||
|
||||
2. **Reference them naturally in conversation**
|
||||
- "Your design mentions using Redis, but we just realized SQLite fits better..."
|
||||
- "The proposal scopes this to premium users, but we're now thinking everyone..."
|
||||
|
||||
3. **Offer to capture when decisions are made**
|
||||
|
||||
| Insight Type | Where to Capture |
|
||||
|--------------|------------------|
|
||||
| New requirement discovered | `specs/<capability>/spec.md` |
|
||||
| Requirement changed | `specs/<capability>/spec.md` |
|
||||
| Design decision made | `design.md` |
|
||||
| Scope changed | `proposal.md` |
|
||||
| New work identified | `tasks.md` |
|
||||
| Assumption invalidated | Relevant artifact |
|
||||
|
||||
Example offers:
|
||||
- "That's a design decision. Capture it in design.md?"
|
||||
- "This is a new requirement. Add it to specs?"
|
||||
- "This changes scope. Update the proposal?"
|
||||
|
||||
4. **The user decides** - Offer and move on. Don't pressure. Don't auto-capture.
|
||||
|
||||
---
|
||||
|
||||
## What You Don't Have To Do
|
||||
|
||||
- Follow a script
|
||||
- Ask the same questions every time
|
||||
- Produce a specific artifact
|
||||
- Reach a conclusion
|
||||
- Stay on topic if a tangent is valuable
|
||||
- Be brief (this is thinking time)
|
||||
|
||||
---
|
||||
|
||||
## Ending Discovery
|
||||
|
||||
There's no required ending. Discovery might:
|
||||
|
||||
- **Flow into a proposal**: "Ready to start? I can create a change proposal."
|
||||
- **Result in artifact updates**: "Updated design.md with these decisions"
|
||||
- **Just provide clarity**: User has what they need, moves on
|
||||
- **Continue later**: "We can pick this up anytime"
|
||||
|
||||
When things crystallize, you might offer a summary - but it's optional. Sometimes the thinking IS the value.
|
||||
|
||||
---
|
||||
|
||||
## Guardrails
|
||||
|
||||
- **Don't implement** - Never write code or implement features. Creating OpenSpec artifacts is fine, writing application code is not.
|
||||
- **Don't fake understanding** - If something is unclear, dig deeper
|
||||
- **Don't rush** - Discovery is thinking time, not task time
|
||||
- **Don't force structure** - Let patterns emerge naturally
|
||||
- **Don't auto-capture** - Offer to save insights, don't just do it
|
||||
- **Do visualize** - A good diagram is worth many paragraphs
|
||||
- **Do explore the codebase** - Ground discussions in reality
|
||||
- **Do question assumptions** - Including the user's and your own
|
||||
106
.agents/prompts/opsx/propose.md
Normal file
106
.agents/prompts/opsx/propose.md
Normal file
@ -0,0 +1,106 @@
|
||||
---
|
||||
name: "OPSX: Propose"
|
||||
description: Propose a new change - create it and generate all artifacts in one step
|
||||
category: Workflow
|
||||
tags: [workflow, artifacts, experimental]
|
||||
---
|
||||
|
||||
Propose a new change - create the change and generate all artifacts in one step.
|
||||
|
||||
I'll create a change with artifacts:
|
||||
- proposal.md (what & why)
|
||||
- design.md (how)
|
||||
- tasks.md (implementation steps)
|
||||
|
||||
When ready to implement, run /opsx:apply
|
||||
|
||||
---
|
||||
|
||||
**Input**: The argument after `/opsx:propose` is the change name (kebab-case), OR a description of what the user wants to build.
|
||||
|
||||
**Steps**
|
||||
|
||||
1. **If no input provided, ask what they want to build**
|
||||
|
||||
Use the **AskUserQuestion tool** (open-ended, no preset options) to ask:
|
||||
> "What change do you want to work on? Describe what you want to build or fix."
|
||||
|
||||
From their description, derive a kebab-case name (e.g., "add user authentication" → `add-user-auth`).
|
||||
|
||||
**IMPORTANT**: Do NOT proceed without understanding what the user wants to build.
|
||||
|
||||
2. **Create the change directory**
|
||||
```bash
|
||||
openspec new change "<name>"
|
||||
```
|
||||
This creates a scaffolded change at `openspec/changes/<name>/` with `.openspec.yaml`.
|
||||
|
||||
3. **Get the artifact build order**
|
||||
```bash
|
||||
openspec status --change "<name>" --json
|
||||
```
|
||||
Parse the JSON to get:
|
||||
- `applyRequires`: array of artifact IDs needed before implementation (e.g., `["tasks"]`)
|
||||
- `artifacts`: list of all artifacts with their status and dependencies
|
||||
|
||||
4. **Create artifacts in sequence until apply-ready**
|
||||
|
||||
Use the **TodoWrite tool** to track progress through the artifacts.
|
||||
|
||||
Loop through artifacts in dependency order (artifacts with no pending dependencies first):
|
||||
|
||||
a. **For each artifact that is `ready` (dependencies satisfied)**:
|
||||
- Get instructions:
|
||||
```bash
|
||||
openspec instructions <artifact-id> --change "<name>" --json
|
||||
```
|
||||
- The instructions JSON includes:
|
||||
- `context`: Project background (constraints for you - do NOT include in output)
|
||||
- `rules`: Artifact-specific rules (constraints for you - do NOT include in output)
|
||||
- `template`: The structure to use for your output file
|
||||
- `instruction`: Schema-specific guidance for this artifact type
|
||||
- `outputPath`: Where to write the artifact
|
||||
- `dependencies`: Completed artifacts to read for context
|
||||
- Read any completed dependency files for context
|
||||
- Create the artifact file using `template` as the structure
|
||||
- Apply `context` and `rules` as constraints - but do NOT copy them into the file
|
||||
- Show brief progress: "Created <artifact-id>"
|
||||
|
||||
b. **Continue until all `applyRequires` artifacts are complete**
|
||||
- After creating each artifact, re-run `openspec status --change "<name>" --json`
|
||||
- Check if every artifact ID in `applyRequires` has `status: "done"` in the artifacts array
|
||||
- Stop when all `applyRequires` artifacts are done
|
||||
|
||||
c. **If an artifact requires user input** (unclear context):
|
||||
- Use **AskUserQuestion tool** to clarify
|
||||
- Then continue with creation
|
||||
|
||||
5. **Show final status**
|
||||
```bash
|
||||
openspec status --change "<name>"
|
||||
```
|
||||
|
||||
**Output**
|
||||
|
||||
After completing all artifacts, summarize:
|
||||
- Change name and location
|
||||
- List of artifacts created with brief descriptions
|
||||
- What's ready: "All artifacts created! Ready for implementation."
|
||||
- Prompt: "Run `/opsx:apply` to start implementing."
|
||||
|
||||
**Artifact Creation Guidelines**
|
||||
|
||||
- Follow the `instruction` field from `openspec instructions` for each artifact type
|
||||
- The schema defines what each artifact should contain - follow it
|
||||
- Read dependency artifacts for context before creating new ones
|
||||
- Use `template` as the structure for your output file - fill in its sections
|
||||
- **IMPORTANT**: `context` and `rules` are constraints for YOU, not content for the file
|
||||
- Do NOT copy `<context>`, `<rules>`, `<project_context>` blocks into the artifact
|
||||
- These guide what you write, but should never appear in the output
|
||||
|
||||
**Guardrails**
|
||||
- Create ALL artifacts needed for implementation (as defined by schema's `apply.requires`)
|
||||
- Always read dependency artifacts before creating a new one
|
||||
- If context is critically unclear, ask the user - but prefer making reasonable decisions to keep momentum
|
||||
- If a change with that name already exists, ask if user wants to continue it or create a new one
|
||||
- Verify each artifact file exists after writing before proceeding to next
|
||||
280
.agents/skills/gf-feedback/SKILL.md
Normal file
280
.agents/skills/gf-feedback/SKILL.md
Normal file
@ -0,0 +1,280 @@
|
||||
---
|
||||
name: gf-feedback
|
||||
description: >-
|
||||
Track, fix, verify, and test any bugs, improvements, or gaps reported against an OpenSpec change.
|
||||
MUST use this skill whenever user reports problems, defects, issues, bugs, or gaps related to
|
||||
existing implementations, even if they don't explicitly say "feedback" or mention OpenSpec.
|
||||
compatibility: Requires openspec CLI, Go toolchain, and gf-review skill.
|
||||
---
|
||||
|
||||
# Feedback: Structured Fix, Verification & Test Coverage Loop
|
||||
|
||||
When users discover bugs or improvement points after implementation, this skill captures those issues, organizes them into a traceable task list in `tasks.md`, systematically fixes and verifies each one, and ensures every behavior-changing fix is covered by focused unit tests.
|
||||
|
||||
**Core principles:**
|
||||
1. **Spec is the source of truth** — Spec-level changes require spec update before task recording
|
||||
2. **Write it down first, then fix it** — Every issue gets recorded before any code change
|
||||
3. **Every fix deserves a test** — Behavior-changing code changes require unit test coverage in the affected package
|
||||
|
||||
---
|
||||
|
||||
## Workflow
|
||||
|
||||
### 1. Identify Target Change
|
||||
|
||||
**CRITICAL:**
|
||||
1. Always append to existing active changes. Only create new change when none exist.
|
||||
2. An **active change** is any change directory that still exists directly under `openspec/changes/` and has **not** been moved into `openspec/changes/archive/`. Do **not** treat `status: complete`, all tasks checked off, or similar completion signals as "inactive" until archive actually happens.
|
||||
3. Regardless of whether the feedback content is related to the main functionality of the current active iteration, it MUST be appended to the current active iteration. This ensures all changes are tracked in a single change record for unified management and archiving.
|
||||
|
||||
```bash
|
||||
openspec list --json
|
||||
# Or: ls openspec/changes/ | grep -v archive
|
||||
```
|
||||
|
||||
When the two signals disagree, prefer the filesystem rule:
|
||||
|
||||
- If a change directory still exists under `openspec/changes/` and is not inside `archive/`, it is active.
|
||||
- `openspec list --json` may still report such a change as `status: complete`; that only means implementation tasks are done, **not** that the change is inactive.
|
||||
- Only archived changes under `openspec/changes/archive/` are inactive.
|
||||
|
||||
| Active Changes | Action |
|
||||
|----------------|--------|
|
||||
| None | Create new change (see below) |
|
||||
| One | Auto-select it, announce and proceed |
|
||||
| Multiple | Ask user to select from list |
|
||||
|
||||
**When multiple active changes exist:**
|
||||
```
|
||||
Multiple active changes detected. Which change should this feedback be appended to?
|
||||
|
||||
1. config-management — System config CRUD management
|
||||
2. user-auth — User authentication enhancement
|
||||
|
||||
Please select 1 or 2:
|
||||
```
|
||||
|
||||
**When no active change exists:**
|
||||
1. Derive kebab-case name from feedback (e.g., "fix-menu-circular-ref")
|
||||
2. If name exists, append suffix ("-2")
|
||||
3. Create: `openspec new change "<name>"`
|
||||
4. Generate minimal `proposal.md` (one paragraph summarizing context)
|
||||
5. Skip `design.md` for pure bug fixes unless architectural changes needed
|
||||
|
||||
Announce: "Applying feedback fixes to change: **<name>**"
|
||||
|
||||
---
|
||||
|
||||
### 2. Read Current Context
|
||||
|
||||
| File | Purpose |
|
||||
|------|---------|
|
||||
| `tasks.md` | Task structure, naming conventions, numbering |
|
||||
| `design.md` | Architectural context |
|
||||
| `proposal.md` | Feature scope and intent |
|
||||
| `specs/` | Delta spec definitions |
|
||||
|
||||
```bash
|
||||
# Locate existing unit tests in the impacted package before adding a new one
|
||||
rg --files <pkg-dir> | rg '_test\\.go$'
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 3. Analyze and Organize Issues
|
||||
|
||||
For each reported issue:
|
||||
|
||||
**Classify by type:**
|
||||
- **bug** — Incorrect behavior, code doesn't match spec
|
||||
- **missing** — Feature incomplete, gaps in implementation
|
||||
- **ux** — UX improvement, no spec change needed
|
||||
- **test-gap** — Missing test coverage only
|
||||
|
||||
**Classify by spec impact:**
|
||||
|
||||
| Level | Definition | Action |
|
||||
|-------|------------|--------|
|
||||
| **implementation** | Spec is correct, code is wrong | Fix code only |
|
||||
| **spec-level** | Requirement missing/incomplete/changed | Update spec first, then fix |
|
||||
| **internal** | No user-observable change | Fix code, test optional |
|
||||
|
||||
**Group related issues** — Same root cause → single task with multiple verification points.
|
||||
|
||||
---
|
||||
|
||||
### 4. Update Delta Specs (for Spec-Level Issues Only)
|
||||
|
||||
For spec-level issues, update specs **before** recording tasks:
|
||||
|
||||
1. Identify affected capability: `specs/<capability>/spec.md`
|
||||
2. Apply delta operation:
|
||||
|
||||
```markdown
|
||||
<!-- ADDED: New requirement -->
|
||||
### Requirement: Parent Selector Circular Prevention
|
||||
The system SHALL disable the current menu and all its descendants in the parent selector
|
||||
to prevent circular references.
|
||||
|
||||
#### Scenario: Edit menu with children
|
||||
WHEN user edits a menu that has child menus
|
||||
THEN the parent selector SHALL disable the current menu and all descendant menus
|
||||
|
||||
<!-- MODIFIED: Changed requirement (include full original block) -->
|
||||
### Requirement: Import Error Handling
|
||||
The system SHALL display error messages when import fails.
|
||||
**MODIFIED:** Error messages SHALL include row number, field name, and validation failure reason.
|
||||
|
||||
<!-- REMOVED: Deprecated requirement -->
|
||||
### Requirement: Legacy Import Format
|
||||
The system SHALL support legacy CSV format.
|
||||
**REMOVED:** This format is no longer supported.
|
||||
**Migration:** Use the new CSV format with header row.
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### 5. Write Task List to tasks.md
|
||||
|
||||
Append a **Feedback section** to `tasks.md`:
|
||||
|
||||
```markdown
|
||||
## Feedback
|
||||
|
||||
- [ ] **FB-1**: Parent selector allows circular references in menu edit
|
||||
- [ ] **FB-2**: Import error messages lack row and field details
|
||||
- [ ] **FB-3**: No test coverage for reset password feature
|
||||
```
|
||||
|
||||
**Numbering:** Sequential `FB-1`, `FB-2`, etc. Continue from last number if section exists.
|
||||
|
||||
**One line per task** — No sub-fields. Analysis happens during fix phase.
|
||||
|
||||
**Confirm with user** before writing to file.
|
||||
|
||||
**Test coverage planning (internal):**
|
||||
- Behavior-changing code change → Unit test required
|
||||
- Internal-only optimization → Unit test optional unless logic risk increased
|
||||
- Prefer extending the nearest `*_z_unit*_test.go` or `*_test.go` in the same package
|
||||
|
||||
---
|
||||
|
||||
### 6. Execute Fixes (Loop)
|
||||
|
||||
For each task:
|
||||
|
||||
**a. Announce:** `## Fixing FB-X: <issue title>`
|
||||
|
||||
**b. Investigate** — Read source files, confirm root cause
|
||||
|
||||
**c. Implement** — Minimal, focused fix following existing patterns
|
||||
|
||||
**d. Write/update unit tests** — Prefer the affected package's existing `*_z_unit*_test.go` or `*_test.go` files and keep assertions focused on the changed logic
|
||||
|
||||
**e. Assess Impact Scope (MANDATORY)**
|
||||
|
||||
After implementing, identify regression risk:
|
||||
|
||||
| Change Type | Map To Tests |
|
||||
|-------------|--------------|
|
||||
| Package-level logic | Targeted test for changed function/method + package regression tests |
|
||||
| Shared utility | Utility package unit tests + highest-value dependent package tests already covering reuse |
|
||||
| DB/DAO logic | DAO/model package unit tests with focused fixtures, mocks, or test helpers |
|
||||
| Public API validation | Handler/service package unit tests that assert the changed validation path |
|
||||
| Refactor without behavior change | Existing package tests that prove behavior parity |
|
||||
|
||||
```bash
|
||||
# Example: Find unit tests related to a changed symbol or package
|
||||
rg -l "GenDao|gdao" . -g '*_test.go'
|
||||
```
|
||||
|
||||
Announce:
|
||||
```
|
||||
### Impact Analysis for FB-X
|
||||
- Modified: cmd/gf/internal/cmd/gendao/gendao.go
|
||||
- Affected package: cmd/gf/internal/cmd/gendao
|
||||
- Unit tests: cmd/gf/internal/cmd/gendao/gendao_test.go
|
||||
- Regression command: go test ./cmd/gf/internal/cmd/gendao -run 'TestGenDao'
|
||||
```
|
||||
|
||||
**f. Verify (MANDATORY before marking complete)**
|
||||
|
||||
1. Run new/updated unit tests for this task → **must pass**
|
||||
2. Run ALL identified package-level regression tests → **must pass**
|
||||
3. Only then: mark task `[x]` in tasks.md
|
||||
|
||||
If regression fails:
|
||||
- Fix inline if related to current change
|
||||
- Add as new FB task if separate issue
|
||||
|
||||
**g. Run review** — Invoke `gf-review` skill after completion
|
||||
|
||||
---
|
||||
|
||||
### 7. Comprehensive Verification
|
||||
|
||||
After all fixes:
|
||||
|
||||
1. Aggregate regression tests from all tasks
|
||||
2. Run full set in single pass
|
||||
3. Report:
|
||||
```
|
||||
### Comprehensive Verification Results
|
||||
- Total tests: N
|
||||
- Passed: N
|
||||
- Failed: N (list with details)
|
||||
- Regression tests: all passed ✓ / X failures
|
||||
```
|
||||
|
||||
If failures → add new FB tasks, loop to Step 6.
|
||||
|
||||
---
|
||||
|
||||
### 8. Report Completion
|
||||
|
||||
```markdown
|
||||
## Feedback Complete
|
||||
|
||||
**Change:** <name>
|
||||
**Issues reported:** X
|
||||
**Issues fixed:** Y/X
|
||||
**Tests added:** Z unit tests / focused assertions
|
||||
**Regression tests run:** R tests across N packages
|
||||
**Verification:** all passed / N issues remaining
|
||||
|
||||
### Fixed This Session
|
||||
- [x] FB-1: <title> ✓ (unit test: TestGenDao_FiltersInvalidTables | package: ./cmd/gf/internal/cmd/gendao ✓)
|
||||
- [x] FB-2: <title> ✓ (unit test: existing package coverage extended | package: ./cmd/gf/internal/cmd ✓)
|
||||
|
||||
### Remaining (if any)
|
||||
- [ ] FB-3: <title> — blocked by <reason>
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Edge Cases
|
||||
|
||||
| Situation | Handling |
|
||||
|-----------|----------|
|
||||
| Single issue | Still follow full workflow |
|
||||
| Missing test cases only | Classify as test-gap, implement tests |
|
||||
| Fix reveals more issues | Add as new FB tasks |
|
||||
| "Bug" is actually feature request | Re-classify as spec-level, update specs first |
|
||||
| Unit test not feasible (docs/spec only) | Note reason explicitly and skip only when no runtime code changes exist |
|
||||
| Multiple feedback rounds | All tasks in single Feedback section, sequential numbering |
|
||||
|
||||
---
|
||||
|
||||
## Guardrails
|
||||
|
||||
- **Append to active change if exists** — Never create new change when active ones exist
|
||||
- **Specs before tasks for spec-level issues** — Update delta specs first
|
||||
- **Write tasks before fixing** — Never code without recording
|
||||
- **Confirm task list with user** — User validates analysis
|
||||
- **Minimal fixes** — No refactoring beyond issue scope
|
||||
- **Behavior-changing fix needs unit test** — No exceptions unless the change is docs/spec only
|
||||
- **No green check without green unit tests** — Mark `[x]` only after tests pass
|
||||
- **Impact analysis mandatory** — Every fix requires package-level regression test identification
|
||||
- **Regression failures block completion** — Must resolve before marking done
|
||||
- **Update tasks.md in real time** — Mark complete immediately after verification
|
||||
- **Match file language** — Use same language as existing content in target file
|
||||
168
.agents/skills/gf-review/SKILL.md
Normal file
168
.agents/skills/gf-review/SKILL.md
Normal file
@ -0,0 +1,168 @@
|
||||
---
|
||||
name: gf-review
|
||||
description: >-
|
||||
Code and specification review for OpenSpec workflow. Triggers automatically after /opsx:apply
|
||||
task completion, after /gf-feedback task completion, and before /opsx:archive. Use when
|
||||
user requests code review, spec compliance check, or when explicitly invoked via /gf-review.
|
||||
compatibility: Requires OpenSpec CLI and GoFrame v2 skill.
|
||||
---
|
||||
|
||||
# GF Review
|
||||
|
||||
Structured code and specification review for the OpenSpec development workflow.
|
||||
|
||||
**Spec Source**: `CLAUDE.md` is the single source of truth for all review criteria.
|
||||
|
||||
---
|
||||
|
||||
## When This Skill Activates
|
||||
|
||||
**Automatic triggers:**
|
||||
- After completing each task in `/opsx:apply`
|
||||
- After completing each task in `/gf-feedback`
|
||||
- Before executing `/opsx:archive`
|
||||
|
||||
**Manual trigger:**
|
||||
- User explicitly requests: "review this code", "check spec compliance", "/gf-review"
|
||||
|
||||
---
|
||||
|
||||
## Review Workflow
|
||||
|
||||
### 1. Identify Scope
|
||||
|
||||
Determine what needs to be reviewed:
|
||||
|
||||
1. **After task completion** — Review files modified/created by the completed task
|
||||
2. **Before archive** — Review all changes in the current OpenSpec change
|
||||
3. **Manual invocation** — Ask user to specify scope or use current change
|
||||
|
||||
**Mandatory scope collection rules:**
|
||||
|
||||
1. Start with repository status, not `git diff` alone:
|
||||
```bash
|
||||
git status --short
|
||||
git ls-files --others --exclude-standard
|
||||
```
|
||||
2. Treat **all tracked and untracked changes** as review candidates, including:
|
||||
- staged files
|
||||
- unstaged files
|
||||
- untracked files shown as `??`
|
||||
- untracked directories shown as `?? path/`
|
||||
3. When `git status --short` reports an untracked directory, expand it to concrete files before review:
|
||||
```bash
|
||||
find <path> -type f
|
||||
# Or prefer:
|
||||
rg --files <path>
|
||||
```
|
||||
4. If the task ran generators such as `make ctrl`, `make dao`, codegen scripts, or produced new test files, explicitly include the generated untracked files in review scope even if they do not appear in `git diff`.
|
||||
5. `git diff` may be used only as a secondary narrowing aid after status collection. It is **never sufficient by itself** for review scope definition.
|
||||
|
||||
Run `openspec status --change "<name>" --json` to understand the current change state.
|
||||
|
||||
### 2. Load Specifications
|
||||
|
||||
Read `CLAUDE.md` to load all specifications. This is the single source of truth.
|
||||
|
||||
### 3. Backend Code Review
|
||||
|
||||
**Trigger**: Changes to files under `apps/lina-core` directory
|
||||
|
||||
1. Invoke `goframe-v2` skill for GoFrame framework conventions
|
||||
2. Check against `CLAUDE.md` backend code specifications
|
||||
|
||||
### 4. RESTful API Review
|
||||
|
||||
**Trigger**: Any API endpoint changes
|
||||
|
||||
Check against `CLAUDE.md` API design specifications.
|
||||
|
||||
### 5. Project Specification Review
|
||||
|
||||
**Trigger**: Any implementation changes
|
||||
|
||||
Check against `CLAUDE.md` architecture design specifications and code development specifications.
|
||||
|
||||
### 6. SQL Review
|
||||
|
||||
**Trigger**: New or modified files under `apps/lina-core/manifest/sql/`、`apps/lina-core/manifest/sql/mock-data/`、`apps/lina-plugins/**/manifest/sql/` or SQL snippets embedded in related delivery docs
|
||||
|
||||
Check against `CLAUDE.md` SQL file management specifications, at minimum covering:
|
||||
1. File naming, versioning, and single-iteration single-file rules
|
||||
2. Seed DML vs mock data separation
|
||||
3. **Idempotent execution safety** — SQL must be safe to run multiple times without duplicate-object errors or duplicate seed data; verify use of `IF [NOT] EXISTS`, `IF EXISTS`, `INSERT IGNORE`, or equivalent safe re-entry patterns
|
||||
4. **Seed write style compliance** — delivered SQL must reject `INSERT ... ON DUPLICATE KEY UPDATE` and reject explicit writes to `AUTO_INCREMENT` `id` columns in seed/mock/install data
|
||||
5. Whether schema/data changes still match the current change scope and deployment path
|
||||
|
||||
### 7. Unit Test Review
|
||||
|
||||
**Trigger**: New or modified Go implementation files, or new/modified Go unit test files matching `*_test.go`
|
||||
|
||||
Check at minimum:
|
||||
1. Behavior-changing Go code includes focused unit coverage in the same package, preferably by extending existing `*_z_unit*_test.go` or `*_test.go`
|
||||
2. Tests assert the changed logic directly instead of relying on broad workflow-level coverage when a package-level test is sufficient
|
||||
3. Verification uses targeted `go test ./path/to/pkg -run TestName` during development and package-level `go test ./path/to/pkg` for regression
|
||||
|
||||
### 8. Generate Review Report
|
||||
|
||||
```markdown
|
||||
## GF Review Report
|
||||
|
||||
**Change:** <change-name>
|
||||
**Scope:** <task-specific / full change>
|
||||
**Files Reviewed:** <count>
|
||||
**Scope Source:** `git status --short` + `git ls-files --others --exclude-standard` + task/change context
|
||||
|
||||
### Backend Code Review
|
||||
✓ All checks passed / ⚠ N issues found
|
||||
|
||||
### RESTful API Review
|
||||
✓ All endpoints compliant / ⚠ N violations found
|
||||
|
||||
### Project Spec Review
|
||||
✓ Compliant with CLAUDE.md / ⚠ N violations found
|
||||
|
||||
### SQL Review
|
||||
✓ No SQL changes / ✓ SQL changes compliant / ⚠ N SQL issues found
|
||||
|
||||
### Unit Test Review
|
||||
✓ Unit tests are focused and sufficient / ⚠ N issues found
|
||||
|
||||
### Summary
|
||||
- **Critical:** N (must fix before archive)
|
||||
- **Warnings:** N (recommended to fix)
|
||||
|
||||
### Recommended Actions
|
||||
1. [Specific action with CLAUDE.md reference]
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Issue Severity
|
||||
|
||||
| Level | Behavior |
|
||||
|-------|----------|
|
||||
| **Critical** | Block archive, must fix |
|
||||
| **Warning** | Show but allow proceed |
|
||||
|
||||
---
|
||||
|
||||
## Integration Points
|
||||
|
||||
| Workflow Step | Behavior |
|
||||
|---------------|----------|
|
||||
| `/opsx:apply` task done | Review, offer to fix issues before next task |
|
||||
| `/gf-feedback` task done | Review, fix before marking complete |
|
||||
| `/opsx:archive` | Review all changes, block on critical issues |
|
||||
|
||||
---
|
||||
|
||||
## Guardrails
|
||||
|
||||
- **CLAUDE.md is the single source of truth** — All spec references point to it
|
||||
- Only check categories relevant to changed files
|
||||
- Scope identification MUST include untracked files and expanded untracked directories; never rely on `git diff` alone
|
||||
- Behavior-changing Go code without focused unit tests is a review finding unless the author documents why tests are not applicable
|
||||
- Don't block on warnings — only critical issues block archive
|
||||
- Include file paths and line numbers in issue reports
|
||||
- Offer to fix issues automatically when straightforward
|
||||
148
.agents/skills/git-commit-push/SKILL.md
Normal file
148
.agents/skills/git-commit-push/SKILL.md
Normal file
@ -0,0 +1,148 @@
|
||||
---
|
||||
name: git-commit-push
|
||||
description: Review the current git working tree, generate a commit message from the actual diff using the repository's commit or PR-title convention, commit all current changes on the active branch, and push that branch to `origin`. Use this whenever the user asks to "commit", "push", "commit and push", "generate a commit message", "commit the current changes", or wants the current branch changes sent upstream without hand-writing the git commands.
|
||||
---
|
||||
|
||||
# Git Commit Push
|
||||
|
||||
Inspect the current repository changes, derive a concise commit subject that matches the repository convention, commit every current modification on the active branch, and push that branch to `origin`.
|
||||
|
||||
This skill is for execution, not just advice. When it triggers, actually run the git workflow unless the repository state makes that unsafe or impossible.
|
||||
|
||||
## When To Use
|
||||
|
||||
- The user asks you to commit the current changes, with or without asking for push
|
||||
- The user wants you to write the commit message from the diff instead of inventing one up front
|
||||
- The user mentions the repo's PR or commit naming convention and wants you to follow it
|
||||
- The user says things like "commit the current branch", "help me commit", "commit and push", "generate a commit message and push", or "send these changes to origin"
|
||||
|
||||
## Core Behavior
|
||||
|
||||
1. Confirm you are inside a Git repository and detect the active branch with `git branch --show-current`.
|
||||
2. Inspect the working tree before committing:
|
||||
- `git status --short --branch`
|
||||
- `git diff --stat`
|
||||
- `git diff --cached --stat`
|
||||
- `git diff -- . ':(exclude)package-lock.json'` or narrower path filters only when needed for readability
|
||||
3. If the repository contains `.github/PULL_REQUEST_TEMPLATE.MD`, read it and treat its PR-title rules as the default commit-subject convention.
|
||||
4. Generate a commit subject from the actual changed files and diff content, not from the user prompt alone.
|
||||
5. Stage every current modification on the branch with `git add -A`.
|
||||
6. Commit once with the generated message.
|
||||
7. Push the current branch to `origin` with `git push origin <current-branch>`.
|
||||
|
||||
## Commit Message Rules
|
||||
|
||||
The commit message is formatted as follows: `<type>[optional scope]: <description>` For example, `fix(os/gtime): fix time zone issue`
|
||||
+ `<type>` is mandatory and can be one of `fix`, `feat`, `build`, `ci`, `docs`, `style`, `refactor`, `perf`, `test`, `chore`
|
||||
+ `fix`: Used when a bug has been fixed.
|
||||
+ `feat`: Used when a new feature has been added.
|
||||
+ `build`: Used for modifications to the project build system, such as changes to dependencies, external interfaces, or upgrading Node version.
|
||||
+ `ci`: Used for modifications to continuous integration processes, such as changes to Travis, Jenkins workflow configurations.
|
||||
+ `docs`: Used for modifications to documentation, such as changes to README files, API documentation, etc.
|
||||
+ `style`: Used for changes to code style, such as adjustments to indentation, spaces, blank lines, etc.
|
||||
+ `refactor`: Used for code refactoring, such as changes to code structure, variable names, function names, without altering functionality.
|
||||
+ `perf`: Used for performance optimization, such as improving code performance, reducing memory usage, etc.
|
||||
+ `test`: Used for modifications to test cases, such as adding, deleting, or modifying test cases for code.
|
||||
+ `chore`: Used for modifications to non-business-related code, such as changes to build processes or tool configurations.
|
||||
+ After `<type>`, specify the affected package name or scope in parentheses, for example, `(os/gtime)`.
|
||||
+ The part after the colon uses the verb tense + phrase that completes the blank in
|
||||
+ Lowercase verb after the colon
|
||||
+ No trailing period
|
||||
+ Keep the title as short as possible. ideally under 76 characters or shorter
|
||||
+ If there is a corresponding issue, add either `fixes #1234` (the latter if this is not a complete fix) to this comment
|
||||
|
||||
### Examples
|
||||
#### Commit message with description and breaking change footer
|
||||
```
|
||||
feat: allow provided config object to extend other configs
|
||||
BREAKING CHANGE: `extends` key in config file is now used for extending other config files
|
||||
```
|
||||
|
||||
#### Commit message with ! to draw attention to breaking change
|
||||
```
|
||||
feat!: send an email to the customer when a product is shipped
|
||||
```
|
||||
|
||||
#### Commit message with scope and ! to draw attention to breaking change
|
||||
```
|
||||
feat(api)!: send an email to the customer when a product is shipped
|
||||
```
|
||||
|
||||
#### Commit message with both ! and BREAKING CHANGE footer
|
||||
```
|
||||
feat!: drop support for Node 6
|
||||
BREAKING CHANGE: use JavaScript features not available in Node 6.
|
||||
```
|
||||
|
||||
#### Commit message with no body
|
||||
```
|
||||
docs: correct spelling of CHANGELOG
|
||||
```
|
||||
|
||||
#### Commit message with scope
|
||||
```
|
||||
feat(lang): add Polish language
|
||||
```
|
||||
|
||||
#### Commit message with multi-paragraph body and multiple footers
|
||||
```
|
||||
fix: prevent racing of requests
|
||||
|
||||
Introduce a request id and a reference to latest request. Dismiss
|
||||
incoming responses other than from latest request.
|
||||
|
||||
Remove timeouts which were used to mitigate the racing issue but are
|
||||
obsolete now.
|
||||
|
||||
Reviewed-by: Z
|
||||
Refs: #123
|
||||
```
|
||||
|
||||
## Execution Rules
|
||||
|
||||
- Commit all current tracked and untracked changes in the working tree, because this skill is for "commit the current state" requests
|
||||
- If there are no changes, say so clearly and stop before commit or push
|
||||
- If `git branch --show-current` is empty, explain that `HEAD` is detached and stop unless the user explicitly asks you to commit from detached `HEAD`
|
||||
- Never use `--force`, `--force-with-lease`, or history-rewriting commands unless the user explicitly asks
|
||||
- If push fails because the remote branch moved, report the exact failure and stop instead of auto-rebasing or auto-merging
|
||||
- Do not silently drop files from the commit unless the user asked to exclude them
|
||||
|
||||
## Suggested Command Flow
|
||||
|
||||
```bash
|
||||
git status --short --branch
|
||||
git diff --stat
|
||||
git diff --cached --stat
|
||||
test -f .github/PULL_REQUEST_TEMPLATE.MD && sed -n '1,220p' .github/PULL_REQUEST_TEMPLATE.MD
|
||||
branch_name=$(git branch --show-current)
|
||||
git add -A
|
||||
git commit -m "<generated-subject>"
|
||||
git push origin "$branch_name"
|
||||
```
|
||||
|
||||
Inspect `git diff --cached` again after staging if the pre-stage diff was noisy or if untracked files materially change the scope.
|
||||
|
||||
## Output Contract
|
||||
|
||||
When you use this skill:
|
||||
|
||||
- Tell the user which branch you committed
|
||||
- Provide the final commit subject you used
|
||||
- Mention that you staged all current changes
|
||||
- Report the push target as `origin/<branch>`
|
||||
- If commit or push did not happen, explain exactly why
|
||||
|
||||
## Example
|
||||
|
||||
User request:
|
||||
|
||||
```text
|
||||
Generate a commit message that follows this repository's convention, then commit and push the current branch
|
||||
```
|
||||
|
||||
Expected behavior:
|
||||
|
||||
- Inspect the repo status and diff
|
||||
- Generate a conventional subject from the real changes
|
||||
- Run one commit for the whole current working tree
|
||||
- Push the active branch to `origin`
|
||||
142
.agents/skills/git-worktree/SKILL.md
Normal file
142
.agents/skills/git-worktree/SKILL.md
Normal file
@ -0,0 +1,142 @@
|
||||
---
|
||||
name: git-worktree
|
||||
description: Create and actively use an isolated git worktree for the user's task, then continue the task inside that new directory. Use this whenever the user asks for a separate worktree, isolated checkout, clean branch directory, safer parallel changes, or a fresh workspace to avoid unrelated local edits.
|
||||
---
|
||||
|
||||
# Git Worktree
|
||||
|
||||
Create a dedicated `git worktree` for the current task, then keep working inside that new directory instead of the original checkout.
|
||||
|
||||
This skill is about execution, not just advice. When it triggers, actually create the worktree unless the repository state makes that impossible.
|
||||
|
||||
Do not introduce helper scripts for this skill. Use direct `git` and shell commands inline.
|
||||
|
||||
## When To Use
|
||||
|
||||
- The user explicitly asks for a new `git worktree`, independent branch directory, or isolated workspace
|
||||
- The current checkout contains unrelated local changes and isolation is the safest way forward
|
||||
- The user wants parallel work on multiple tasks without stashing or disturbing the original worktree
|
||||
- The user says things like "create a separate branch folder", "open a fresh worktree", "use a clean checkout", or "work in an isolated workspace"
|
||||
|
||||
## Core Rule
|
||||
|
||||
After creating the worktree, treat the new path as the active working directory for the rest of the task.
|
||||
|
||||
In any agent environment, "enter the directory" means:
|
||||
|
||||
- Run subsequent commands against the new worktree path
|
||||
- Apply all edits under that worktree path
|
||||
- Do not keep using the original checkout by accident
|
||||
- Confirm the handoff by running at least one follow-up command in the new worktree
|
||||
|
||||
Never claim you "switched" unless your subsequent actions actually target the new `worktree_path`.
|
||||
|
||||
If your environment supports a per-command working directory, use it for every later command. If it does not, prefix later commands with an explicit `cd <worktree_path> && ...`.
|
||||
|
||||
## Name Derivation
|
||||
|
||||
- Derive a short ASCII kebab-case task slug from the user's real task, such as `login-timeout-fix` or `user-export`
|
||||
- Do not use generic names like `git-worktree`, `new-worktree`, or `task` unless the request is too vague
|
||||
- If the request is mostly non-ASCII or no good slug is obvious, fall back to `task-$(date +%Y%m%d-%H%M%S)`
|
||||
- Default branch prefix is `worktree/`
|
||||
- Default worktree directory is a sibling of the repository root, named `<repo-name>-<slug>`
|
||||
|
||||
## Default Workflow
|
||||
|
||||
1. Inspect the repository context from the current checkout:
|
||||
- `git rev-parse --show-toplevel`
|
||||
- `git branch --show-current`
|
||||
- `git status --short`
|
||||
- `git worktree list --porcelain`
|
||||
2. Decide a task slug yourself using the rules above
|
||||
3. Build branch and path names inline, then create the worktree with direct shell commands like:
|
||||
|
||||
```bash
|
||||
repo_root=$(git rev-parse --show-toplevel)
|
||||
repo_name=$(basename "$repo_root")
|
||||
parent_dir=$(dirname "$repo_root")
|
||||
source_branch=$(git -C "$repo_root" branch --show-current)
|
||||
if [ -n "$source_branch" ]; then
|
||||
source_ref="$source_branch"
|
||||
else
|
||||
source_ref="HEAD@$(git -C "$repo_root" rev-parse --short HEAD)"
|
||||
fi
|
||||
|
||||
slug="<task-slug>"
|
||||
base_branch="worktree/$slug"
|
||||
branch_name="$base_branch"
|
||||
base_path="$parent_dir/$repo_name-$slug"
|
||||
worktree_path="$base_path"
|
||||
index=2
|
||||
|
||||
while git -C "$repo_root" show-ref --verify --quiet "refs/heads/$branch_name" || [ -e "$worktree_path" ]; do
|
||||
branch_name="${base_branch}-$index"
|
||||
worktree_path="${base_path}-$index"
|
||||
index=$((index + 1))
|
||||
done
|
||||
|
||||
git -C "$repo_root" worktree add -b "$branch_name" "$worktree_path" HEAD
|
||||
```
|
||||
|
||||
4. Immediately verify the handoff inside the new worktree, for example:
|
||||
|
||||
```bash
|
||||
pwd
|
||||
git status --short --branch
|
||||
```
|
||||
|
||||
These verification commands must run against `worktree_path`.
|
||||
|
||||
5. Announce the new active path briefly, then continue the main task there
|
||||
6. For the remainder of the task, use `worktree_path` as the working directory for every relevant command or edit operation
|
||||
|
||||
## Behavior Rules
|
||||
|
||||
- Default base ref is `HEAD` from the current checkout so uncommitted local changes are not dragged into the new worktree
|
||||
- If a branch name or path already exists, auto-increment it instead of failing
|
||||
- If you are already inside a non-default worktree and the user still wants another isolated workspace, create a new one from the current `HEAD`
|
||||
- If the directory is not a Git repository, explain that clearly and do not pretend a worktree was created
|
||||
- If worktree creation succeeds, continue the user's actual task instead of stopping at setup
|
||||
- If worktree creation fails because of filesystem permissions, request the minimal approval needed and retry
|
||||
|
||||
## Uncommitted Change Policy
|
||||
|
||||
The safe default is isolation from uncommitted changes.
|
||||
|
||||
- If the source checkout is dirty, still create the new worktree from `HEAD` unless the user explicitly asks to carry local edits over
|
||||
- Do not silently stash, reset, or move the user's existing changes
|
||||
- If the user wants local edits copied into the new worktree, use an explicit flow such as a temporary commit, patch, or cherry-pick, and say what you are doing
|
||||
|
||||
## Output Contract
|
||||
|
||||
When you use this skill:
|
||||
|
||||
- Tell the user which branch and directory were created
|
||||
- Make it clear that subsequent work is now happening inside that path
|
||||
- Mention the source ref and whether the original checkout was dirty when that context matters
|
||||
- Do not stop after setup if the user asked for additional work; continue the task in the new worktree
|
||||
|
||||
## Example
|
||||
|
||||
User request:
|
||||
|
||||
```text
|
||||
Create a separate worktree for this task and then start implementing it.
|
||||
```
|
||||
|
||||
Expected behavior:
|
||||
|
||||
- Inspect current repo status
|
||||
- Create a new `worktree/...` branch and sibling directory with direct `git worktree` commands
|
||||
- Switch all following commands to that directory
|
||||
- Continue the requested implementation there
|
||||
|
||||
## Cleanup
|
||||
|
||||
Only remove a worktree when the user asks or when cleanup is clearly part of the task.
|
||||
|
||||
Before cleanup:
|
||||
|
||||
- Check status in the worktree you created
|
||||
- Make sure you are removing the correct path
|
||||
- Never remove the user's original checkout
|
||||
288
.agents/skills/openspec-explore/SKILL.md
Normal file
288
.agents/skills/openspec-explore/SKILL.md
Normal file
@ -0,0 +1,288 @@
|
||||
---
|
||||
name: openspec-explore
|
||||
description: Enter explore mode - a thinking partner for exploring ideas, investigating problems, and clarifying requirements. Use when the user wants to think through something before or during a change.
|
||||
license: MIT
|
||||
compatibility: Requires openspec CLI.
|
||||
metadata:
|
||||
author: openspec
|
||||
version: "1.0"
|
||||
generatedBy: "1.2.0"
|
||||
---
|
||||
|
||||
Enter explore mode. Think deeply. Visualize freely. Follow the conversation wherever it goes.
|
||||
|
||||
**IMPORTANT: Explore mode is for thinking, not implementing.** You may read files, search code, and investigate the codebase, but you must NEVER write code or implement features. If the user asks you to implement something, remind them to exit explore mode first and create a change proposal. You MAY create OpenSpec artifacts (proposals, designs, specs) if the user asks—that's capturing thinking, not implementing.
|
||||
|
||||
**This is a stance, not a workflow.** There are no fixed steps, no required sequence, no mandatory outputs. You're a thinking partner helping the user explore.
|
||||
|
||||
---
|
||||
|
||||
## The Stance
|
||||
|
||||
- **Curious, not prescriptive** - Ask questions that emerge naturally, don't follow a script
|
||||
- **Open threads, not interrogations** - Surface multiple interesting directions and let the user follow what resonates. Don't funnel them through a single path of questions.
|
||||
- **Visual** - Use ASCII diagrams liberally when they'd help clarify thinking
|
||||
- **Adaptive** - Follow interesting threads, pivot when new information emerges
|
||||
- **Patient** - Don't rush to conclusions, let the shape of the problem emerge
|
||||
- **Grounded** - Explore the actual codebase when relevant, don't just theorize
|
||||
|
||||
---
|
||||
|
||||
## What You Might Do
|
||||
|
||||
Depending on what the user brings, you might:
|
||||
|
||||
**Explore the problem space**
|
||||
- Ask clarifying questions that emerge from what they said
|
||||
- Challenge assumptions
|
||||
- Reframe the problem
|
||||
- Find analogies
|
||||
|
||||
**Investigate the codebase**
|
||||
- Map existing architecture relevant to the discussion
|
||||
- Find integration points
|
||||
- Identify patterns already in use
|
||||
- Surface hidden complexity
|
||||
|
||||
**Compare options**
|
||||
- Brainstorm multiple approaches
|
||||
- Build comparison tables
|
||||
- Sketch tradeoffs
|
||||
- Recommend a path (if asked)
|
||||
|
||||
**Visualize**
|
||||
```
|
||||
┌─────────────────────────────────────────┐
|
||||
│ Use ASCII diagrams liberally │
|
||||
├─────────────────────────────────────────┤
|
||||
│ │
|
||||
│ ┌────────┐ ┌────────┐ │
|
||||
│ │ State │────────▶│ State │ │
|
||||
│ │ A │ │ B │ │
|
||||
│ └────────┘ └────────┘ │
|
||||
│ │
|
||||
│ System diagrams, state machines, │
|
||||
│ data flows, architecture sketches, │
|
||||
│ dependency graphs, comparison tables │
|
||||
│ │
|
||||
└─────────────────────────────────────────┘
|
||||
```
|
||||
|
||||
**Surface risks and unknowns**
|
||||
- Identify what could go wrong
|
||||
- Find gaps in understanding
|
||||
- Suggest spikes or investigations
|
||||
|
||||
---
|
||||
|
||||
## OpenSpec Awareness
|
||||
|
||||
You have full context of the OpenSpec system. Use it naturally, don't force it.
|
||||
|
||||
### Check for context
|
||||
|
||||
At the start, quickly check what exists:
|
||||
```bash
|
||||
openspec list --json
|
||||
```
|
||||
|
||||
This tells you:
|
||||
- If there are active changes
|
||||
- Their names, schemas, and status
|
||||
- What the user might be working on
|
||||
|
||||
### When no change exists
|
||||
|
||||
Think freely. When insights crystallize, you might offer:
|
||||
|
||||
- "This feels solid enough to start a change. Want me to create a proposal?"
|
||||
- Or keep exploring - no pressure to formalize
|
||||
|
||||
### When a change exists
|
||||
|
||||
If the user mentions a change or you detect one is relevant:
|
||||
|
||||
1. **Read existing artifacts for context**
|
||||
- `openspec/changes/<name>/proposal.md`
|
||||
- `openspec/changes/<name>/design.md`
|
||||
- `openspec/changes/<name>/tasks.md`
|
||||
- etc.
|
||||
|
||||
2. **Reference them naturally in conversation**
|
||||
- "Your design mentions using Redis, but we just realized SQLite fits better..."
|
||||
- "The proposal scopes this to premium users, but we're now thinking everyone..."
|
||||
|
||||
3. **Offer to capture when decisions are made**
|
||||
|
||||
| Insight Type | Where to Capture |
|
||||
|--------------|------------------|
|
||||
| New requirement discovered | `specs/<capability>/spec.md` |
|
||||
| Requirement changed | `specs/<capability>/spec.md` |
|
||||
| Design decision made | `design.md` |
|
||||
| Scope changed | `proposal.md` |
|
||||
| New work identified | `tasks.md` |
|
||||
| Assumption invalidated | Relevant artifact |
|
||||
|
||||
Example offers:
|
||||
- "That's a design decision. Capture it in design.md?"
|
||||
- "This is a new requirement. Add it to specs?"
|
||||
- "This changes scope. Update the proposal?"
|
||||
|
||||
4. **The user decides** - Offer and move on. Don't pressure. Don't auto-capture.
|
||||
|
||||
---
|
||||
|
||||
## What You Don't Have To Do
|
||||
|
||||
- Follow a script
|
||||
- Ask the same questions every time
|
||||
- Produce a specific artifact
|
||||
- Reach a conclusion
|
||||
- Stay on topic if a tangent is valuable
|
||||
- Be brief (this is thinking time)
|
||||
|
||||
---
|
||||
|
||||
## Handling Different Entry Points
|
||||
|
||||
**User brings a vague idea:**
|
||||
```
|
||||
User: I'm thinking about adding real-time collaboration
|
||||
|
||||
You: Real-time collab is a big space. Let me think about this...
|
||||
|
||||
COLLABORATION SPECTRUM
|
||||
════════════════════════════════════════════
|
||||
|
||||
Awareness Coordination Sync
|
||||
│ │ │
|
||||
▼ ▼ ▼
|
||||
┌────────┐ ┌────────┐ ┌────────┐
|
||||
│Presence│ │Cursors │ │ CRDT │
|
||||
│ "3 │ │ Multi │ │Conflict│
|
||||
│online" │ │ select │ │ free │
|
||||
└────────┘ └────────┘ └────────┘
|
||||
│ │ │
|
||||
trivial moderate complex
|
||||
|
||||
Where's your head at?
|
||||
```
|
||||
|
||||
**User brings a specific problem:**
|
||||
```
|
||||
User: The auth system is a mess
|
||||
|
||||
You: [reads codebase]
|
||||
|
||||
┌─────────────────────────────────────────────┐
|
||||
│ CURRENT AUTH FLOW │
|
||||
└─────────────────────────────────────────────┘
|
||||
│
|
||||
┌─────────────┼─────────────┐
|
||||
▼ ▼ ▼
|
||||
┌─────────┐ ┌─────────┐ ┌─────────┐
|
||||
│ Google │ │ GitHub │ │ Email │
|
||||
│ OAuth │ │ OAuth │ │ Magic │
|
||||
└────┬────┘ └────┬────┘ └────┬────┘
|
||||
│ │ │
|
||||
└─────────────┼─────────────┘
|
||||
▼
|
||||
┌───────────┐
|
||||
│ Session │
|
||||
└─────┬─────┘
|
||||
│
|
||||
▼
|
||||
┌───────────┐
|
||||
│ Perms │
|
||||
└───────────┘
|
||||
|
||||
I see three tangles. Which one's burning?
|
||||
```
|
||||
|
||||
**User is stuck mid-implementation:**
|
||||
```
|
||||
User: /opsx:explore add-auth-system
|
||||
The OAuth integration is more complex than expected
|
||||
|
||||
You: [reads change artifacts]
|
||||
|
||||
You're on task 4: "Implement OAuth flow"
|
||||
|
||||
Let me trace what's involved...
|
||||
|
||||
[draws diagram, explores options, suggests paths]
|
||||
|
||||
Want to update the design to reflect this?
|
||||
Or add a spike task to investigate?
|
||||
```
|
||||
|
||||
**User wants to compare options:**
|
||||
```
|
||||
User: Should we use Postgres or SQLite?
|
||||
|
||||
You: Generic answer is boring. What's the context?
|
||||
|
||||
User: A CLI tool that tracks local dev environments
|
||||
|
||||
You: That changes everything.
|
||||
|
||||
┌─────────────────────────────────────────────────┐
|
||||
│ CLI TOOL DATA STORAGE │
|
||||
└─────────────────────────────────────────────────┘
|
||||
|
||||
Key constraints:
|
||||
• No daemon running
|
||||
• Must work offline
|
||||
• Single user
|
||||
|
||||
SQLite Postgres
|
||||
Deployment embedded ✓ needs server ✗
|
||||
Offline yes ✓ no ✗
|
||||
Single file yes ✓ no ✗
|
||||
|
||||
SQLite. Not even close.
|
||||
|
||||
Unless... is there a sync component?
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Ending Discovery
|
||||
|
||||
There's no required ending. Discovery might:
|
||||
|
||||
- **Flow into a proposal**: "Ready to start? I can create a change proposal."
|
||||
- **Result in artifact updates**: "Updated design.md with these decisions"
|
||||
- **Just provide clarity**: User has what they need, moves on
|
||||
- **Continue later**: "We can pick this up anytime"
|
||||
|
||||
When it feels like things are crystallizing, you might summarize:
|
||||
|
||||
```
|
||||
## What We Figured Out
|
||||
|
||||
**The problem**: [crystallized understanding]
|
||||
|
||||
**The approach**: [if one emerged]
|
||||
|
||||
**Open questions**: [if any remain]
|
||||
|
||||
**Next steps** (if ready):
|
||||
- Create a change proposal
|
||||
- Keep exploring: just keep talking
|
||||
```
|
||||
|
||||
But this summary is optional. Sometimes the thinking IS the value.
|
||||
|
||||
---
|
||||
|
||||
## Guardrails
|
||||
|
||||
- **Don't implement** - Never write code or implement features. Creating OpenSpec artifacts is fine, writing application code is not.
|
||||
- **Don't fake understanding** - If something is unclear, dig deeper
|
||||
- **Don't rush** - Discovery is thinking time, not task time
|
||||
- **Don't force structure** - Let patterns emerge naturally
|
||||
- **Don't auto-capture** - Offer to save insights, don't just do it
|
||||
- **Do visualize** - A good diagram is worth many paragraphs
|
||||
- **Do explore the codebase** - Ground discussions in reality
|
||||
- **Do question assumptions** - Including the user's and your own
|
||||
110
.agents/skills/openspec-propose/SKILL.md
Normal file
110
.agents/skills/openspec-propose/SKILL.md
Normal file
@ -0,0 +1,110 @@
|
||||
---
|
||||
name: openspec-propose
|
||||
description: Propose a new change with all artifacts generated in one step. Use when the user wants to quickly describe what they want to build and get a complete proposal with design, specs, and tasks ready for implementation.
|
||||
license: MIT
|
||||
compatibility: Requires openspec CLI.
|
||||
metadata:
|
||||
author: openspec
|
||||
version: "1.0"
|
||||
generatedBy: "1.2.0"
|
||||
---
|
||||
|
||||
Propose a new change - create the change and generate all artifacts in one step.
|
||||
|
||||
I'll create a change with artifacts:
|
||||
- proposal.md (what & why)
|
||||
- design.md (how)
|
||||
- tasks.md (implementation steps)
|
||||
|
||||
When ready to implement, run /opsx:apply
|
||||
|
||||
---
|
||||
|
||||
**Input**: The user's request should include a change name (kebab-case) OR a description of what they want to build.
|
||||
|
||||
**Steps**
|
||||
|
||||
1. **If no clear input provided, ask what they want to build**
|
||||
|
||||
Use the **AskUserQuestion tool** (open-ended, no preset options) to ask:
|
||||
> "What change do you want to work on? Describe what you want to build or fix."
|
||||
|
||||
From their description, derive a kebab-case name (e.g., "add user authentication" → `add-user-auth`).
|
||||
|
||||
**IMPORTANT**: Do NOT proceed without understanding what the user wants to build.
|
||||
|
||||
2. **Create the change directory**
|
||||
```bash
|
||||
openspec new change "<name>"
|
||||
```
|
||||
This creates a scaffolded change at `openspec/changes/<name>/` with `.openspec.yaml`.
|
||||
|
||||
3. **Get the artifact build order**
|
||||
```bash
|
||||
openspec status --change "<name>" --json
|
||||
```
|
||||
Parse the JSON to get:
|
||||
- `applyRequires`: array of artifact IDs needed before implementation (e.g., `["tasks"]`)
|
||||
- `artifacts`: list of all artifacts with their status and dependencies
|
||||
|
||||
4. **Create artifacts in sequence until apply-ready**
|
||||
|
||||
Use the **TodoWrite tool** to track progress through the artifacts.
|
||||
|
||||
Loop through artifacts in dependency order (artifacts with no pending dependencies first):
|
||||
|
||||
a. **For each artifact that is `ready` (dependencies satisfied)**:
|
||||
- Get instructions:
|
||||
```bash
|
||||
openspec instructions <artifact-id> --change "<name>" --json
|
||||
```
|
||||
- The instructions JSON includes:
|
||||
- `context`: Project background (constraints for you - do NOT include in output)
|
||||
- `rules`: Artifact-specific rules (constraints for you - do NOT include in output)
|
||||
- `template`: The structure to use for your output file
|
||||
- `instruction`: Schema-specific guidance for this artifact type
|
||||
- `outputPath`: Where to write the artifact
|
||||
- `dependencies`: Completed artifacts to read for context
|
||||
- Read any completed dependency files for context
|
||||
- Create the artifact file using `template` as the structure
|
||||
- Apply `context` and `rules` as constraints - but do NOT copy them into the file
|
||||
- Show brief progress: "Created <artifact-id>"
|
||||
|
||||
b. **Continue until all `applyRequires` artifacts are complete**
|
||||
- After creating each artifact, re-run `openspec status --change "<name>" --json`
|
||||
- Check if every artifact ID in `applyRequires` has `status: "done"` in the artifacts array
|
||||
- Stop when all `applyRequires` artifacts are done
|
||||
|
||||
c. **If an artifact requires user input** (unclear context):
|
||||
- Use **AskUserQuestion tool** to clarify
|
||||
- Then continue with creation
|
||||
|
||||
5. **Show final status**
|
||||
```bash
|
||||
openspec status --change "<name>"
|
||||
```
|
||||
|
||||
**Output**
|
||||
|
||||
After completing all artifacts, summarize:
|
||||
- Change name and location
|
||||
- List of artifacts created with brief descriptions
|
||||
- What's ready: "All artifacts created! Ready for implementation."
|
||||
- Prompt: "Run `/opsx:apply` or ask me to implement to start working on the tasks."
|
||||
|
||||
**Artifact Creation Guidelines**
|
||||
|
||||
- Follow the `instruction` field from `openspec instructions` for each artifact type
|
||||
- The schema defines what each artifact should contain - follow it
|
||||
- Read dependency artifacts for context before creating new ones
|
||||
- Use `template` as the structure for your output file - fill in its sections
|
||||
- **IMPORTANT**: `context` and `rules` are constraints for YOU, not content for the file
|
||||
- Do NOT copy `<context>`, `<rules>`, `<project_context>` blocks into the artifact
|
||||
- These guide what you write, but should never appear in the output
|
||||
|
||||
**Guardrails**
|
||||
- Create ALL artifacts needed for implementation (as defined by schema's `apply.requires`)
|
||||
- Always read dependency artifacts before creating a new one
|
||||
- If context is critically unclear, ask the user - but prefer making reasonable decisions to keep momentum
|
||||
- If a change with that name already exists, ask if user wants to continue it or create a new one
|
||||
- Verify each artifact file exists after writing before proceeding to next
|
||||
1
.claude/commands
Symbolic link
1
.claude/commands
Symbolic link
@ -0,0 +1 @@
|
||||
../.agents/prompts
|
||||
1
.claude/skills
Symbolic link
1
.claude/skills
Symbolic link
@ -0,0 +1 @@
|
||||
../.agents/skills
|
||||
2
.codecov.yml
Normal file
2
.codecov.yml
Normal file
@ -0,0 +1,2 @@
|
||||
ignore:
|
||||
- "cmd" # ignore cmd folders and all its contents
|
||||
5
.codex/config.toml
Normal file
5
.codex/config.toml
Normal file
@ -0,0 +1,5 @@
|
||||
approval_policy = "never"
|
||||
sandbox_mode = "danger-full-access"
|
||||
|
||||
[sandbox_workspace_write]
|
||||
network_access = true
|
||||
37
.gitee/ISSUE_TEMPLATE
Normal file
37
.gitee/ISSUE_TEMPLATE
Normal file
@ -0,0 +1,37 @@
|
||||
<!-- 为高效处理您的疑问,如果觉得是BUG类问题,请您务必提供可复现该问题的最小可运行代码! -->
|
||||
<!-- 为高效处理您的疑问,如果觉得是BUG类问题,请您务必提供可复现该问题的最小可运行代码! -->
|
||||
<!-- 为高效处理您的疑问,如果觉得是BUG类问题,请您务必提供可复现该问题的最小可运行代码! -->
|
||||
<!-- 重要的事情说三遍! -->
|
||||
|
||||
### 1. 您当前使用的`Go`版本,及系统版本、系统架构?
|
||||
|
||||
<!-- 使用 `go version` 命令查看,期望的结果如:`go 1.12, linux/amd64` -->
|
||||
|
||||
|
||||
### 2. 您当前使用的`GoFrame`框架版本?
|
||||
|
||||
<!-- 框架版本可以查看自己项目下的 `go.mod`,或者框架文件 `version.go` -->
|
||||
|
||||
|
||||
### 3. 更新到最新的框架版本是否能够解决问题?
|
||||
|
||||
<!-- 务必检查是否相同问题已在新版本中已修复 -->
|
||||
|
||||
|
||||
### 4. 问题描述?
|
||||
|
||||
<!--
|
||||
请您尽可能地提供一份最短的,可复现问题的代码。
|
||||
代码尽可能地完整,最好是可以直接编译运行。
|
||||
-->
|
||||
|
||||
|
||||
|
||||
### 5. 您期望得到的结果?
|
||||
|
||||
|
||||
|
||||
### 6. 您实际得到的结果?
|
||||
|
||||
|
||||
|
||||
@ -1,34 +0,0 @@
|
||||
<!-- 为更高效率地交流并解决问题,请按照以下模板提交issue,感谢! -->
|
||||
|
||||
### 1. 您当前使用的`Go`版本,及系统版本、系统架构?
|
||||
|
||||
<!-- 使用 `go version` 命令查看,期望的结果如:`go 1.12, linux/amd64` -->
|
||||
|
||||
|
||||
### 2. 您当前使用的`GoFrame`框架版本?
|
||||
|
||||
<!-- 框架版本可以查看自己项目下的 `go.mod`,或者框架文件 `version.go` -->
|
||||
|
||||
|
||||
### 3. 更新到最新的框架版本是否能够解决问题?
|
||||
|
||||
<!-- 务必检查是否相同问题已在新版本中已修复 -->
|
||||
|
||||
|
||||
### 4. 问题描述?
|
||||
|
||||
<!--
|
||||
请您尽可能地提供一份最短的,可复现问题的代码。
|
||||
代码尽可能地完整,最好是可以直接编译运行。
|
||||
-->
|
||||
|
||||
|
||||
|
||||
### 5. 您期望得到的结果?
|
||||
|
||||
|
||||
|
||||
### 6. 您实际得到的结果?
|
||||
|
||||
|
||||
|
||||
12
.github/FUNDING.yml
vendored
Normal file
12
.github/FUNDING.yml
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
# These are supported funding model platforms
|
||||
|
||||
github: [gogf] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
|
||||
patreon: # Replace with a single Patreon username
|
||||
open_collective: # Replace with a single Open Collective username
|
||||
ko_fi: # Replace with a single Ko-fi username
|
||||
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
|
||||
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
|
||||
liberapay: # Replace with a single Liberapay username
|
||||
issuehunt: # Replace with a single IssueHunt username
|
||||
otechie: # Replace with a single Otechie username
|
||||
custom: # custom
|
||||
36
.github/ISSUE_TEMPLATE.MD
vendored
36
.github/ISSUE_TEMPLATE.MD
vendored
@ -1,36 +0,0 @@
|
||||
<!-- Please answer these questions before submitting your issue. Thanks! -->
|
||||
|
||||
### 1. What version of `Go` and system type/arch are you using?
|
||||
|
||||
<!--
|
||||
Please paste the output of command `go version` from your terminal.
|
||||
What expect to see is like: `go 1.12, linux/amd64`
|
||||
-->
|
||||
|
||||
|
||||
### 2. What version of `GoFrame` are you using?
|
||||
|
||||
<!-- You can find the GF version from your `go.mod`, or from the `version.go` in `GF` -->
|
||||
|
||||
|
||||
### 3. Can this issue be reproduced with the latest release?
|
||||
|
||||
|
||||
|
||||
### 4. What did you do?
|
||||
|
||||
<!--
|
||||
If possible, provide a copy of shortest codes for reproducing the error.
|
||||
A complete runnable program is best.
|
||||
-->
|
||||
|
||||
|
||||
|
||||
### 5. What did you expect to see?
|
||||
|
||||
|
||||
|
||||
### 6. What did you see instead?
|
||||
|
||||
|
||||
|
||||
71
.github/ISSUE_TEMPLATE/00-bug.yml
vendored
Normal file
71
.github/ISSUE_TEMPLATE/00-bug.yml
vendored
Normal file
@ -0,0 +1,71 @@
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository#creating-issue-forms
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
|
||||
name: Bugs
|
||||
description: GoFrame command, module, or anything else
|
||||
title: "os/gtime: issue title"
|
||||
labels:
|
||||
- bug
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for helping us improve! 🙏 Please answer these questions and provide as much information as possible about your problem.
|
||||
|
||||
The issue title uses the format of the package name goes before the colon. Thanks!
|
||||
|
||||
标题使用包名在冒号前的格式!谢谢!
|
||||
|
||||
- type: input
|
||||
id: go-version
|
||||
attributes:
|
||||
label: Go version
|
||||
description: |
|
||||
What version of Go are you using (`go version`)?
|
||||
placeholder: ex. go version go1.20.7 darwin/arm64
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: input
|
||||
id: gf-version
|
||||
attributes:
|
||||
label: GoFrame version
|
||||
description: |
|
||||
What version of GoFrame are you using (`gf version`)?
|
||||
placeholder: ex. 2.7.0
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: dropdown
|
||||
id: is-reproducible
|
||||
attributes:
|
||||
label: Can this bug be reproduced with the latest release?
|
||||
options:
|
||||
- Option Yes
|
||||
- Option No
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
id: what-did-you-do
|
||||
attributes:
|
||||
label: "What did you do?"
|
||||
description: "If possible, provide a recipe for reproducing the error. A complete runnable program is good. A link on [go.dev/play](https://go.dev/play) is best."
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
id: actual-behavior
|
||||
attributes:
|
||||
label: "What did you see happen?"
|
||||
description: Command invocations and their associated output, functions with their arguments and return results, full stacktraces for panics (upload a file if it is very long), etc. Prefer copying text output over using screenshots.
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
id: expected-behavior
|
||||
attributes:
|
||||
label: "What did you expect to see?"
|
||||
description: Why is the current output incorrect, and any additional context we may need to understand the issue.
|
||||
validations:
|
||||
required: true
|
||||
32
.github/ISSUE_TEMPLATE/01-enhance.yml
vendored
Normal file
32
.github/ISSUE_TEMPLATE/01-enhance.yml
vendored
Normal file
@ -0,0 +1,32 @@
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository#creating-issue-forms
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
|
||||
name: Enhancements
|
||||
description: Enhance an idea for this project
|
||||
title: "os/gtime: issue title"
|
||||
labels:
|
||||
- enhancement
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for helping us improve! 🙏 Please answer these questions and provide as much information as possible about your problem.
|
||||
|
||||
The issue title uses the format of the package name goes before the colon. Thanks!
|
||||
|
||||
标题使用包名在冒号前的格式!谢谢!
|
||||
|
||||
- type: textarea
|
||||
id: description
|
||||
attributes:
|
||||
label: "Description"
|
||||
description: "Please describe your idea in detail."
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
id: additional
|
||||
attributes:
|
||||
label: "Additional"
|
||||
validations:
|
||||
required: false
|
||||
48
.github/ISSUE_TEMPLATE/02-feature.yml
vendored
Normal file
48
.github/ISSUE_TEMPLATE/02-feature.yml
vendored
Normal file
@ -0,0 +1,48 @@
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository#creating-issue-forms
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
|
||||
name: Features
|
||||
description: Suggest an idea for this project
|
||||
title: "os/gtime: issue title"
|
||||
labels:
|
||||
- feature
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for helping us improve! 🙏 Please answer these questions and provide as much information as possible about your problem.
|
||||
|
||||
The issue title uses the format of the package name goes before the colon. Thanks!
|
||||
|
||||
标题使用包名在冒号前的格式!谢谢!
|
||||
|
||||
- type: dropdown
|
||||
id: is-problem
|
||||
attributes:
|
||||
label: Is your feature request related to a problem?
|
||||
options:
|
||||
- Option Yes
|
||||
- Option No
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
id: description-solution
|
||||
attributes:
|
||||
label: "Describe the solution you'd like"
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
id: description-considered
|
||||
attributes:
|
||||
label: "Describe alternatives you've considered"
|
||||
validations:
|
||||
required: true
|
||||
|
||||
- type: textarea
|
||||
id: additional
|
||||
attributes:
|
||||
label: "Additional"
|
||||
validations:
|
||||
required: false
|
||||
25
.github/ISSUE_TEMPLATE/03-question.yml
vendored
Normal file
25
.github/ISSUE_TEMPLATE/03-question.yml
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository#creating-issue-forms
|
||||
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
|
||||
name: Questions
|
||||
description: I want to ask a question
|
||||
title: "os/gtime: issue title"
|
||||
labels:
|
||||
- question
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Please read the document carefully. 请先仔细阅读文档
|
||||
|
||||
The issue title uses the format of the package name goes before the colon. Thanks!
|
||||
|
||||
标题使用包名在冒号前的格式!谢谢!
|
||||
|
||||
- type: textarea
|
||||
id: ask
|
||||
attributes:
|
||||
label: "What do you want to ask?"
|
||||
description: "Please describe the details of your questions. 请详细描述你的问题。"
|
||||
validations:
|
||||
required: true
|
||||
44
.github/PULL_REQUEST_TEMPLATE.MD
vendored
Normal file
44
.github/PULL_REQUEST_TEMPLATE.MD
vendored
Normal file
@ -0,0 +1,44 @@
|
||||
**Please ensure you adhere to every item in this list.**
|
||||
+ The PR title is formatted as follows: `<type>[optional scope]: <description>` For example, `fix(os/gtime): fix time zone issue`
|
||||
+ `<type>` is mandatory and can be one of `fix`, `feat`, `build`, `ci`, `docs`, `style`, `refactor`, `perf`, `test`, `chore`
|
||||
+ `fix`: Used when a bug has been fixed.
|
||||
+ `feat`: Used when a new feature has been added.
|
||||
+ `build`: Used for modifications to the project build system, such as changes to dependencies, external interfaces, or upgrading Node version.
|
||||
+ `ci`: Used for modifications to continuous integration processes, such as changes to Travis, Jenkins workflow configurations.
|
||||
+ `docs`: Used for modifications to documentation, such as changes to README files, API documentation, etc.
|
||||
+ `style`: Used for changes to code style, such as adjustments to indentation, spaces, blank lines, etc.
|
||||
+ `refactor`: Used for code refactoring, such as changes to code structure, variable names, function names, without altering functionality.
|
||||
+ `perf`: Used for performance optimization, such as improving code performance, reducing memory usage, etc.
|
||||
+ `test`: Used for modifications to test cases, such as adding, deleting, or modifying test cases for code.
|
||||
+ `chore`: Used for modifications to non-business-related code, such as changes to build processes or tool configurations.
|
||||
+ After `<type>`, specify the affected package name or scope in parentheses, for example, `(os/gtime)`.
|
||||
+ The part after the colon uses the verb tense + phrase that completes the blank in
|
||||
+ Lowercase verb after the colon
|
||||
+ No trailing period
|
||||
+ Keep the title as short as possible. ideally under 76 characters or shorter
|
||||
+ [Reference Documentation](https://www.conventionalcommits.org/en/v1.0.0/)
|
||||
+ If there is a corresponding issue, add either `Fixes #1234` or `Updates #1234`
|
||||
(the latter if this is not a complete fix) to this comment
|
||||
+ Delete these instructions once you have read and applied them
|
||||
|
||||
**提交前请遵守每个事项,感谢!**
|
||||
+ PR 标题格式如下:`<类型>[可选 范围]: <描述>` 例如 `fix(os/gtime): fix time zone issue`
|
||||
+ `<类型>`是必须的,可以是 `fix`、`feat`、`build`、`ci`、`docs`、`style`、`refactor`、`perf`、`test`、`chore` 中的一个
|
||||
+ fix: 用于修复了一个 bug
|
||||
+ feat: 用于新增了一个功能
|
||||
+ build: 用于修改项目构建系统,例如修改依赖库、外部接口或者升级 Node 版本等
|
||||
+ ci: 用于修改持续集成流程,例如修改 Travis、Jenkins 等工作流配置
|
||||
+ docs: 用于修改文档,例如修改 README 文件、API 文档等
|
||||
+ style: 用于修改代码的样式,例如调整缩进、空格、空行等
|
||||
+ refactor: 用于重构代码,例如修改代码结构、变量名、函数名等但不修改功能逻辑
|
||||
+ perf: 用于优化性能,例如提升代码的性能、减少内存占用等
|
||||
+ test: 用于修改测试用例,例如添加、删除、修改代码的测试用例等
|
||||
+ chore: 用于对非业务性代码进行修改,例如修改构建流程或者工具配置等
|
||||
+ `<类型>`后在括号中填写受影响的包名或范围,例如 `(os/gtime)`
|
||||
+ 冒号后使用动词时态 + 短语
|
||||
+ 冒号后的动词小写
|
||||
+ 不要有结尾句号
|
||||
+ 标题尽量保持简短,最好在 76 个字符或更短
|
||||
+ [参考文档](https://www.conventionalcommits.org/zh-hans/v1.0.0/)
|
||||
+ 如果有对应的 issue,请在此评论中添加 `Fixes #1234`,如果不是完全修复则添加 `Updates #1234`
|
||||
+ 应用这些规则后删除所有的说明
|
||||
BIN
.github/logo.png
vendored
Normal file
BIN
.github/logo.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 232 KiB |
42
.github/workflows/apollo/docker-compose.yml
vendored
Normal file
42
.github/workflows/apollo/docker-compose.yml
vendored
Normal file
@ -0,0 +1,42 @@
|
||||
version: '2'
|
||||
|
||||
services:
|
||||
apollo-quick-start:
|
||||
image: "loads/apollo-quick-start:latest"
|
||||
container_name: apollo-quick-start
|
||||
depends_on:
|
||||
- apollo-db
|
||||
ports:
|
||||
- "8080:8080"
|
||||
- "8070:8070"
|
||||
- "8060:8060"
|
||||
links:
|
||||
- apollo-db
|
||||
#environment:
|
||||
#JAVA_OPTS: '-Xms100m -Xmx1000m -Xmn100m -Xss256k -XX:MetaspaceSize=10m -XX:MaxMetaspaceSize=250m'
|
||||
#APOLLO_CONFIG_DB_USERNAME: 'root'
|
||||
#APOLLO_CONFIG_DB_PASSWORD: 'apollo'
|
||||
#APOLLO_PORTAL_DB_USERNAME: 'root'
|
||||
#APOLLO_PORTAL_DB_PASSWORD: 'apollo'
|
||||
|
||||
apollo-db:
|
||||
image: "mysql:5.7"
|
||||
container_name: apollo-db
|
||||
environment:
|
||||
TZ: Asia/Shanghai
|
||||
MYSQL_ALLOW_EMPTY_PASSWORD: 'yes'
|
||||
#MYSQL_ROOT_PASSWORD: 'apollo'
|
||||
depends_on:
|
||||
- apollo-dbdata
|
||||
ports:
|
||||
- "13306:3306"
|
||||
volumes:
|
||||
- ./sql:/docker-entrypoint-initdb.d
|
||||
volumes_from:
|
||||
- apollo-dbdata
|
||||
|
||||
apollo-dbdata:
|
||||
image: "alpine:3.8"
|
||||
container_name: apollo-dbdata
|
||||
volumes:
|
||||
- /var/lib/mysql
|
||||
467
.github/workflows/apollo/sql/apolloconfigdb.sql
vendored
Normal file
467
.github/workflows/apollo/sql/apolloconfigdb.sql
vendored
Normal file
@ -0,0 +1,467 @@
|
||||
--
|
||||
-- Copyright 2022 Apollo Authors
|
||||
--
|
||||
-- Licensed under the Apache License, Version 2.0 (the "License");
|
||||
-- you may not use this file except in compliance with the License.
|
||||
-- You may obtain a copy of the License at
|
||||
--
|
||||
-- http://www.apache.org/licenses/LICENSE-2.0
|
||||
--
|
||||
-- Unless required by applicable law or agreed to in writing, software
|
||||
-- distributed under the License is distributed on an "AS IS" BASIS,
|
||||
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
-- See the License for the specific language governing permissions and
|
||||
-- limitations under the License.
|
||||
--
|
||||
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||
/*!40101 SET NAMES utf8 */;
|
||||
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
|
||||
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
|
||||
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
|
||||
|
||||
# Create Database
|
||||
# ------------------------------------------------------------
|
||||
CREATE DATABASE IF NOT EXISTS ApolloConfigDB DEFAULT CHARACTER SET = utf8mb4;
|
||||
|
||||
Use ApolloConfigDB;
|
||||
|
||||
# Dump of table app
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `App`;
|
||||
|
||||
CREATE TABLE `App` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键',
|
||||
`AppId` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`Name` varchar(500) NOT NULL DEFAULT 'default' COMMENT '应用名',
|
||||
`OrgId` varchar(32) NOT NULL DEFAULT 'default' COMMENT '部门Id',
|
||||
`OrgName` varchar(64) NOT NULL DEFAULT 'default' COMMENT '部门名字',
|
||||
`OwnerName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'ownerName',
|
||||
`OwnerEmail` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'ownerEmail',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_AppId_DeletedAt` (`AppId`,`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_Name` (`Name`(191))
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='应用表';
|
||||
|
||||
|
||||
|
||||
# Dump of table appnamespace
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `AppNamespace`;
|
||||
|
||||
CREATE TABLE `AppNamespace` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增主键',
|
||||
`Name` varchar(32) NOT NULL DEFAULT '' COMMENT 'namespace名字,注意,需要全局唯一',
|
||||
`AppId` varchar(64) NOT NULL DEFAULT '' COMMENT 'app id',
|
||||
`Format` varchar(32) NOT NULL DEFAULT 'properties' COMMENT 'namespace的format类型',
|
||||
`IsPublic` bit(1) NOT NULL DEFAULT b'0' COMMENT 'namespace是否为公共',
|
||||
`Comment` varchar(64) NOT NULL DEFAULT '' COMMENT '注释',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_AppId_Name_DeletedAt` (`AppId`,`Name`,`DeletedAt`),
|
||||
KEY `Name_AppId` (`Name`,`AppId`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='应用namespace定义';
|
||||
|
||||
|
||||
|
||||
# Dump of table audit
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Audit`;
|
||||
|
||||
CREATE TABLE `Audit` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键',
|
||||
`EntityName` varchar(50) NOT NULL DEFAULT 'default' COMMENT '表名',
|
||||
`EntityId` int(10) unsigned DEFAULT NULL COMMENT '记录ID',
|
||||
`OpName` varchar(50) NOT NULL DEFAULT 'default' COMMENT '操作类型',
|
||||
`Comment` varchar(500) DEFAULT NULL COMMENT '备注',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='日志审计表';
|
||||
|
||||
|
||||
|
||||
# Dump of table cluster
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Cluster`;
|
||||
|
||||
CREATE TABLE `Cluster` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增主键',
|
||||
`Name` varchar(32) NOT NULL DEFAULT '' COMMENT '集群名字',
|
||||
`AppId` varchar(64) NOT NULL DEFAULT '' COMMENT 'App id',
|
||||
`ParentClusterId` int(10) unsigned NOT NULL DEFAULT '0' COMMENT '父cluster',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_AppId_Name_DeletedAt` (`AppId`,`Name`,`DeletedAt`),
|
||||
KEY `IX_ParentClusterId` (`ParentClusterId`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='集群';
|
||||
|
||||
|
||||
|
||||
# Dump of table commit
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Commit`;
|
||||
|
||||
CREATE TABLE `Commit` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键',
|
||||
`ChangeSets` longtext NOT NULL COMMENT '修改变更集',
|
||||
`AppId` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`ClusterName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'ClusterName',
|
||||
`NamespaceName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'namespaceName',
|
||||
`Comment` varchar(500) DEFAULT NULL COMMENT '备注',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `AppId` (`AppId`(191)),
|
||||
KEY `ClusterName` (`ClusterName`(191)),
|
||||
KEY `NamespaceName` (`NamespaceName`(191))
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='commit 历史表';
|
||||
|
||||
# Dump of table grayreleaserule
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `GrayReleaseRule`;
|
||||
|
||||
CREATE TABLE `GrayReleaseRule` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键',
|
||||
`AppId` varchar(64) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`ClusterName` varchar(32) NOT NULL DEFAULT 'default' COMMENT 'Cluster Name',
|
||||
`NamespaceName` varchar(32) NOT NULL DEFAULT 'default' COMMENT 'Namespace Name',
|
||||
`BranchName` varchar(32) NOT NULL DEFAULT 'default' COMMENT 'branch name',
|
||||
`Rules` varchar(16000) DEFAULT '[]' COMMENT '灰度规则',
|
||||
`ReleaseId` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '灰度对应的release',
|
||||
`BranchStatus` tinyint(2) DEFAULT '1' COMMENT '灰度分支状态: 0:删除分支,1:正在使用的规则 2:全量发布',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_Namespace` (`AppId`,`ClusterName`,`NamespaceName`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='灰度规则表';
|
||||
|
||||
|
||||
# Dump of table instance
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Instance`;
|
||||
|
||||
CREATE TABLE `Instance` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`AppId` varchar(64) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`ClusterName` varchar(32) NOT NULL DEFAULT 'default' COMMENT 'ClusterName',
|
||||
`DataCenter` varchar(64) NOT NULL DEFAULT 'default' COMMENT 'Data Center Name',
|
||||
`Ip` varchar(32) NOT NULL DEFAULT '' COMMENT 'instance ip',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `IX_UNIQUE_KEY` (`AppId`,`ClusterName`,`Ip`,`DataCenter`),
|
||||
KEY `IX_IP` (`Ip`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='使用配置的应用实例';
|
||||
|
||||
|
||||
|
||||
# Dump of table instanceconfig
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `InstanceConfig`;
|
||||
|
||||
CREATE TABLE `InstanceConfig` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`InstanceId` int(11) unsigned DEFAULT NULL COMMENT 'Instance Id',
|
||||
`ConfigAppId` varchar(64) NOT NULL DEFAULT 'default' COMMENT 'Config App Id',
|
||||
`ConfigClusterName` varchar(32) NOT NULL DEFAULT 'default' COMMENT 'Config Cluster Name',
|
||||
`ConfigNamespaceName` varchar(32) NOT NULL DEFAULT 'default' COMMENT 'Config Namespace Name',
|
||||
`ReleaseKey` varchar(64) NOT NULL DEFAULT '' COMMENT '发布的Key',
|
||||
`ReleaseDeliveryTime` timestamp NULL DEFAULT NULL COMMENT '配置获取时间',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `IX_UNIQUE_KEY` (`InstanceId`,`ConfigAppId`,`ConfigNamespaceName`),
|
||||
KEY `IX_ReleaseKey` (`ReleaseKey`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_Valid_Namespace` (`ConfigAppId`,`ConfigClusterName`,`ConfigNamespaceName`,`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='应用实例的配置信息';
|
||||
|
||||
|
||||
|
||||
# Dump of table item
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Item`;
|
||||
|
||||
CREATE TABLE `Item` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`NamespaceId` int(10) unsigned NOT NULL DEFAULT '0' COMMENT '集群NamespaceId',
|
||||
`Key` varchar(128) NOT NULL DEFAULT 'default' COMMENT '配置项Key',
|
||||
`Value` longtext NOT NULL COMMENT '配置项值',
|
||||
`Comment` varchar(1024) DEFAULT '' COMMENT '注释',
|
||||
`LineNum` int(10) unsigned DEFAULT '0' COMMENT '行号',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
KEY `IX_GroupId` (`NamespaceId`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='配置项目';
|
||||
|
||||
|
||||
|
||||
# Dump of table namespace
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Namespace`;
|
||||
|
||||
CREATE TABLE `Namespace` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增主键',
|
||||
`AppId` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`ClusterName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'Cluster Name',
|
||||
`NamespaceName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'Namespace Name',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_AppId_ClusterName_NamespaceName_DeletedAt` (`AppId`(191),`ClusterName`(191),`NamespaceName`(191),`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_NamespaceName` (`NamespaceName`(191))
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='命名空间';
|
||||
|
||||
|
||||
|
||||
# Dump of table namespacelock
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `NamespaceLock`;
|
||||
|
||||
CREATE TABLE `NamespaceLock` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增id',
|
||||
`NamespaceId` int(10) unsigned NOT NULL DEFAULT '0' COMMENT '集群NamespaceId',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
`IsDeleted` bit(1) DEFAULT b'0' COMMENT '软删除',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_NamespaceId_DeletedAt` (`NamespaceId`,`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='namespace的编辑锁';
|
||||
|
||||
|
||||
|
||||
# Dump of table release
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Release`;
|
||||
|
||||
CREATE TABLE `Release` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增主键',
|
||||
`ReleaseKey` varchar(64) NOT NULL DEFAULT '' COMMENT '发布的Key',
|
||||
`Name` varchar(64) NOT NULL DEFAULT 'default' COMMENT '发布名字',
|
||||
`Comment` varchar(256) DEFAULT NULL COMMENT '发布说明',
|
||||
`AppId` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`ClusterName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'ClusterName',
|
||||
`NamespaceName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'namespaceName',
|
||||
`Configurations` longtext NOT NULL COMMENT '发布配置',
|
||||
`IsAbandoned` bit(1) NOT NULL DEFAULT b'0' COMMENT '是否废弃',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_ReleaseKey_DeletedAt` (`ReleaseKey`,`DeletedAt`),
|
||||
KEY `AppId_ClusterName_GroupName` (`AppId`(191),`ClusterName`(191),`NamespaceName`(191)),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='发布';
|
||||
|
||||
|
||||
# Dump of table releasehistory
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `ReleaseHistory`;
|
||||
|
||||
CREATE TABLE `ReleaseHistory` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`AppId` varchar(64) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`ClusterName` varchar(32) NOT NULL DEFAULT 'default' COMMENT 'ClusterName',
|
||||
`NamespaceName` varchar(32) NOT NULL DEFAULT 'default' COMMENT 'namespaceName',
|
||||
`BranchName` varchar(32) NOT NULL DEFAULT 'default' COMMENT '发布分支名',
|
||||
`ReleaseId` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '关联的Release Id',
|
||||
`PreviousReleaseId` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '前一次发布的ReleaseId',
|
||||
`Operation` tinyint(3) unsigned NOT NULL DEFAULT '0' COMMENT '发布类型,0: 普通发布,1: 回滚,2: 灰度发布,3: 灰度规则更新,4: 灰度合并回主分支发布,5: 主分支发布灰度自动发布,6: 主分支回滚灰度自动发布,7: 放弃灰度',
|
||||
`OperationContext` longtext NOT NULL COMMENT '发布上下文信息',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
KEY `IX_Namespace` (`AppId`,`ClusterName`,`NamespaceName`,`BranchName`),
|
||||
KEY `IX_ReleaseId` (`ReleaseId`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='发布历史';
|
||||
|
||||
|
||||
# Dump of table releasemessage
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `ReleaseMessage`;
|
||||
|
||||
CREATE TABLE `ReleaseMessage` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增主键',
|
||||
`Message` varchar(1024) NOT NULL DEFAULT '' COMMENT '发布的消息内容',
|
||||
`DataChange_LastTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_Message` (`Message`(191))
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='发布消息';
|
||||
|
||||
|
||||
|
||||
# Dump of table serverconfig
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `ServerConfig`;
|
||||
|
||||
CREATE TABLE `ServerConfig` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`Key` varchar(64) NOT NULL DEFAULT 'default' COMMENT '配置项Key',
|
||||
`Cluster` varchar(32) NOT NULL DEFAULT 'default' COMMENT '配置对应的集群,default为不针对特定的集群',
|
||||
`Value` varchar(2048) NOT NULL DEFAULT 'default' COMMENT '配置项值',
|
||||
`Comment` varchar(1024) DEFAULT '' COMMENT '注释',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_Key_Cluster_DeletedAt` (`Key`,`Cluster`,`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='配置服务自身配置';
|
||||
|
||||
# Dump of table accesskey
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `AccessKey`;
|
||||
|
||||
CREATE TABLE `AccessKey` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增主键',
|
||||
`AppId` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`Secret` varchar(128) NOT NULL DEFAULT '' COMMENT 'Secret',
|
||||
`IsEnabled` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: enabled, 0: disabled',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_AppId_Secret_DeletedAt` (`AppId`,`Secret`,`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='访问密钥';
|
||||
|
||||
# Config
|
||||
# ------------------------------------------------------------
|
||||
INSERT INTO `ServerConfig` (`Key`, `Cluster`, `Value`, `Comment`)
|
||||
VALUES
|
||||
('eureka.service.url', 'default', 'http://localhost:8080/eureka/', 'Eureka服务Url,多个service以英文逗号分隔'),
|
||||
('namespace.lock.switch', 'default', 'false', '一次发布只能有一个人修改开关'),
|
||||
('item.value.length.limit', 'default', '20000', 'item value最大长度限制'),
|
||||
('config-service.cache.enabled', 'default', 'false', 'ConfigService是否开启缓存,开启后能提高性能,但是会增大内存消耗!'),
|
||||
('item.key.length.limit', 'default', '128', 'item key 最大长度限制');
|
||||
|
||||
# Sample Data
|
||||
# ------------------------------------------------------------
|
||||
INSERT INTO `App` (`AppId`, `Name`, `OrgId`, `OrgName`, `OwnerName`, `OwnerEmail`)
|
||||
VALUES
|
||||
('SampleApp', 'Sample App', 'TEST1', '样例部门1', 'apollo', 'apollo@acme.com');
|
||||
|
||||
INSERT INTO `AppNamespace` (`Name`, `AppId`, `Format`, `IsPublic`, `Comment`)
|
||||
VALUES
|
||||
('application', 'SampleApp', 'properties', 0, 'default app namespace');
|
||||
|
||||
INSERT INTO `Cluster` (`Name`, `AppId`)
|
||||
VALUES
|
||||
('default', 'SampleApp');
|
||||
|
||||
INSERT INTO `Namespace` (`Id`, `AppId`, `ClusterName`, `NamespaceName`)
|
||||
VALUES
|
||||
(1, 'SampleApp', 'default', 'application');
|
||||
|
||||
|
||||
INSERT INTO `Item` VALUES (1,1,'timeout','100','sample timeout配置',1,_binary '\0',0,'default','2022-09-28 15:43:17','','2022-09-28 15:43:17'),
|
||||
(2,1,'','','',2,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(3,1,'server.address',':8000','',3,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(4,1,'server.dumpRouterMap','true','',4,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(5,1,'server.routeOverWrite','true','',5,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(6,1,'server.accessLogEnabled','true','',6,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(7,1,'server.openapiPath','/api.json','',7,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(8,1,'server.swaggerPath','/swagger','',8,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(9,1,'','','',9,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(10,1,'','','# Global logging.',10,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(11,1,'logger.level','all','',11,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55'),
|
||||
(12,1,'logger.stdout','true','',12,_binary '\0',0,'apollo','2022-09-28 15:47:55','apollo','2022-09-28 15:47:55');
|
||||
|
||||
INSERT INTO `Release` VALUES (1,'20161009155425-d3a0749c6e20bc15','20161009155424-release','Sample发布','SampleApp','default','application','{\"timeout\":\"100\"}',_binary '\0',_binary '\0',0,'default','2022-09-28 15:59:38','','2022-09-28 15:59:38'),
|
||||
(2,'20220929000151-1dc5634459e19171','20220929000148-release','','SampleApp','default','application','{\"timeout\":\"100\",\"server.address\":\":8000\",\"server.dumpRouterMap\":\"true\",\"server.routeOverWrite\":\"true\",\"server.accessLogEnabled\":\"true\",\"server.openapiPath\":\"/api.json\",\"server.swaggerPath\":\"/swagger\",\"logger.level\":\"all\",\"logger.stdout\":\"true\"}',_binary '\0',_binary '\0',0,'apollo','2022-09-28 16:01:51','apollo','2022-09-28 16:01:51');
|
||||
|
||||
INSERT INTO `ReleaseHistory` VALUES (1,'SampleApp','default','application','default',1,0,0,'{}',_binary '\0',0,'apollo','2022-09-28 15:59:38','apollo','2022-09-28 15:59:38'),
|
||||
(2,'SampleApp','default','application','default',2,1,0,'{\"isEmergencyPublish\":false}',_binary '\0',0,'apollo','2022-09-28 16:01:51','apollo','2022-09-28 16:01:51');
|
||||
|
||||
INSERT INTO `ReleaseMessage` VALUES (1,'SampleApp+default+application','2022-09-28 15:59:38'),
|
||||
(2,'SampleApp+default+application','2022-09-28 16:01:51');
|
||||
|
||||
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
|
||||
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
|
||||
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
|
||||
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
||||
420
.github/workflows/apollo/sql/apolloportaldb.sql
vendored
Normal file
420
.github/workflows/apollo/sql/apolloportaldb.sql
vendored
Normal file
@ -0,0 +1,420 @@
|
||||
--
|
||||
-- Copyright 2022 Apollo Authors
|
||||
--
|
||||
-- Licensed under the Apache License, Version 2.0 (the "License");
|
||||
-- you may not use this file except in compliance with the License.
|
||||
-- You may obtain a copy of the License at
|
||||
--
|
||||
-- http://www.apache.org/licenses/LICENSE-2.0
|
||||
--
|
||||
-- Unless required by applicable law or agreed to in writing, software
|
||||
-- distributed under the License is distributed on an "AS IS" BASIS,
|
||||
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
-- See the License for the specific language governing permissions and
|
||||
-- limitations under the License.
|
||||
--
|
||||
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||
/*!40101 SET NAMES utf8 */;
|
||||
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
|
||||
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
|
||||
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
|
||||
|
||||
# Create Database
|
||||
# ------------------------------------------------------------
|
||||
CREATE DATABASE IF NOT EXISTS ApolloPortalDB DEFAULT CHARACTER SET = utf8mb4;
|
||||
|
||||
Use ApolloPortalDB;
|
||||
|
||||
# Dump of table app
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `App`;
|
||||
|
||||
CREATE TABLE `App` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键',
|
||||
`AppId` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`Name` varchar(500) NOT NULL DEFAULT 'default' COMMENT '应用名',
|
||||
`OrgId` varchar(32) NOT NULL DEFAULT 'default' COMMENT '部门Id',
|
||||
`OrgName` varchar(64) NOT NULL DEFAULT 'default' COMMENT '部门名字',
|
||||
`OwnerName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'ownerName',
|
||||
`OwnerEmail` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'ownerEmail',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_AppId_DeletedAt` (`AppId`,`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_Name` (`Name`(191))
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='应用表';
|
||||
|
||||
|
||||
|
||||
# Dump of table appnamespace
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `AppNamespace`;
|
||||
|
||||
CREATE TABLE `AppNamespace` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增主键',
|
||||
`Name` varchar(32) NOT NULL DEFAULT '' COMMENT 'namespace名字,注意,需要全局唯一',
|
||||
`AppId` varchar(64) NOT NULL DEFAULT '' COMMENT 'app id',
|
||||
`Format` varchar(32) NOT NULL DEFAULT 'properties' COMMENT 'namespace的format类型',
|
||||
`IsPublic` bit(1) NOT NULL DEFAULT b'0' COMMENT 'namespace是否为公共',
|
||||
`Comment` varchar(64) NOT NULL DEFAULT '' COMMENT '注释',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_AppId_Name_DeletedAt` (`AppId`,`Name`,`DeletedAt`),
|
||||
KEY `Name_AppId` (`Name`,`AppId`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='应用namespace定义';
|
||||
|
||||
|
||||
|
||||
# Dump of table consumer
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Consumer`;
|
||||
|
||||
CREATE TABLE `Consumer` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`AppId` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`Name` varchar(500) NOT NULL DEFAULT 'default' COMMENT '应用名',
|
||||
`OrgId` varchar(32) NOT NULL DEFAULT 'default' COMMENT '部门Id',
|
||||
`OrgName` varchar(64) NOT NULL DEFAULT 'default' COMMENT '部门名字',
|
||||
`OwnerName` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'ownerName',
|
||||
`OwnerEmail` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'ownerEmail',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_AppId_DeletedAt` (`AppId`,`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='开放API消费者';
|
||||
|
||||
|
||||
|
||||
# Dump of table consumeraudit
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `ConsumerAudit`;
|
||||
|
||||
CREATE TABLE `ConsumerAudit` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`ConsumerId` int(11) unsigned DEFAULT NULL COMMENT 'Consumer Id',
|
||||
`Uri` varchar(1024) NOT NULL DEFAULT '' COMMENT '访问的Uri',
|
||||
`Method` varchar(16) NOT NULL DEFAULT '' COMMENT '访问的Method',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_ConsumerId` (`ConsumerId`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='consumer审计表';
|
||||
|
||||
|
||||
|
||||
# Dump of table consumerrole
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `ConsumerRole`;
|
||||
|
||||
CREATE TABLE `ConsumerRole` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`ConsumerId` int(11) unsigned DEFAULT NULL COMMENT 'Consumer Id',
|
||||
`RoleId` int(10) unsigned DEFAULT NULL COMMENT 'Role Id',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_ConsumerId_RoleId_DeletedAt` (`ConsumerId`,`RoleId`,`DeletedAt`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_RoleId` (`RoleId`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='consumer和role的绑定表';
|
||||
|
||||
|
||||
|
||||
# Dump of table consumertoken
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `ConsumerToken`;
|
||||
|
||||
CREATE TABLE `ConsumerToken` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`ConsumerId` int(11) unsigned DEFAULT NULL COMMENT 'ConsumerId',
|
||||
`Token` varchar(128) NOT NULL DEFAULT '' COMMENT 'token',
|
||||
`Expires` datetime NOT NULL DEFAULT '2099-01-01 00:00:00' COMMENT 'token失效时间',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_Token_DeletedAt` (`Token`,`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='consumer token表';
|
||||
|
||||
# Dump of table favorite
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Favorite`;
|
||||
|
||||
CREATE TABLE `Favorite` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键',
|
||||
`UserId` varchar(32) NOT NULL DEFAULT 'default' COMMENT '收藏的用户',
|
||||
`AppId` varchar(500) NOT NULL DEFAULT 'default' COMMENT 'AppID',
|
||||
`Position` int(32) NOT NULL DEFAULT '10000' COMMENT '收藏顺序',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_UserId_AppId_DeletedAt` (`UserId`,`AppId`,`DeletedAt`),
|
||||
KEY `AppId` (`AppId`(191)),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=23 DEFAULT CHARSET=utf8mb4 COMMENT='应用收藏表';
|
||||
|
||||
# Dump of table permission
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Permission`;
|
||||
|
||||
CREATE TABLE `Permission` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`PermissionType` varchar(32) NOT NULL DEFAULT '' COMMENT '权限类型',
|
||||
`TargetId` varchar(256) NOT NULL DEFAULT '' COMMENT '权限对象类型',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_TargetId_PermissionType_DeletedAt` (`TargetId`,`PermissionType`,`DeletedAt`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='permission表';
|
||||
|
||||
|
||||
|
||||
# Dump of table role
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Role`;
|
||||
|
||||
CREATE TABLE `Role` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`RoleName` varchar(256) NOT NULL DEFAULT '' COMMENT 'Role name',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_RoleName_DeletedAt` (`RoleName`,`DeletedAt`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='角色表';
|
||||
|
||||
|
||||
|
||||
# Dump of table rolepermission
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `RolePermission`;
|
||||
|
||||
CREATE TABLE `RolePermission` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`RoleId` int(10) unsigned DEFAULT NULL COMMENT 'Role Id',
|
||||
`PermissionId` int(10) unsigned DEFAULT NULL COMMENT 'Permission Id',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_RoleId_PermissionId_DeletedAt` (`RoleId`,`PermissionId`,`DeletedAt`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_PermissionId` (`PermissionId`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='角色和权限的绑定表';
|
||||
|
||||
|
||||
|
||||
# Dump of table serverconfig
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `ServerConfig`;
|
||||
|
||||
CREATE TABLE `ServerConfig` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`Key` varchar(64) NOT NULL DEFAULT 'default' COMMENT '配置项Key',
|
||||
`Value` varchar(2048) NOT NULL DEFAULT 'default' COMMENT '配置项值',
|
||||
`Comment` varchar(1024) DEFAULT '' COMMENT '注释',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_Key_DeletedAt` (`Key`,`DeletedAt`),
|
||||
KEY `DataChange_LastTime` (`DataChange_LastTime`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='配置服务自身配置';
|
||||
|
||||
|
||||
|
||||
# Dump of table userrole
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `UserRole`;
|
||||
|
||||
CREATE TABLE `UserRole` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`UserId` varchar(128) DEFAULT '' COMMENT '用户身份标识',
|
||||
`RoleId` int(10) unsigned DEFAULT NULL COMMENT 'Role Id',
|
||||
`IsDeleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '1: deleted, 0: normal',
|
||||
`DeletedAt` BIGINT(20) NOT NULL DEFAULT '0' COMMENT 'Delete timestamp based on milliseconds',
|
||||
`DataChange_CreatedBy` varchar(64) NOT NULL DEFAULT 'default' COMMENT '创建人邮箱前缀',
|
||||
`DataChange_CreatedTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`DataChange_LastModifiedBy` varchar(64) DEFAULT '' COMMENT '最后修改人邮箱前缀',
|
||||
`DataChange_LastTime` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后修改时间',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_UserId_RoleId_DeletedAt` (`UserId`,`RoleId`,`DeletedAt`),
|
||||
KEY `IX_DataChange_LastTime` (`DataChange_LastTime`),
|
||||
KEY `IX_RoleId` (`RoleId`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='用户和role的绑定表';
|
||||
|
||||
# Dump of table Users
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Users`;
|
||||
|
||||
CREATE TABLE `Users` (
|
||||
`Id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`Username` varchar(64) NOT NULL DEFAULT 'default' COMMENT '用户登录账户',
|
||||
`Password` varchar(512) NOT NULL DEFAULT 'default' COMMENT '密码',
|
||||
`UserDisplayName` varchar(512) NOT NULL DEFAULT 'default' COMMENT '用户名称',
|
||||
`Email` varchar(64) NOT NULL DEFAULT 'default' COMMENT '邮箱地址',
|
||||
`Enabled` tinyint(4) DEFAULT NULL COMMENT '是否有效',
|
||||
PRIMARY KEY (`Id`),
|
||||
UNIQUE KEY `UK_Username` (`Username`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='用户表';
|
||||
|
||||
|
||||
# Dump of table Authorities
|
||||
# ------------------------------------------------------------
|
||||
|
||||
DROP TABLE IF EXISTS `Authorities`;
|
||||
|
||||
CREATE TABLE `Authorities` (
|
||||
`Id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增Id',
|
||||
`Username` varchar(64) NOT NULL,
|
||||
`Authority` varchar(50) NOT NULL,
|
||||
PRIMARY KEY (`Id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
|
||||
|
||||
|
||||
# Config
|
||||
# ------------------------------------------------------------
|
||||
INSERT INTO `ServerConfig` (`Key`, `Value`, `Comment`)
|
||||
VALUES
|
||||
('apollo.portal.envs', 'dev', '可支持的环境列表'),
|
||||
('organizations', '[{\"orgId\":\"TEST1\",\"orgName\":\"样例部门1\"},{\"orgId\":\"TEST2\",\"orgName\":\"样例部门2\"}]', '部门列表'),
|
||||
('superAdmin', 'apollo', 'Portal超级管理员'),
|
||||
('api.readTimeout', '10000', 'http接口read timeout'),
|
||||
('consumer.token.salt', 'someSalt', 'consumer token salt'),
|
||||
('admin.createPrivateNamespace.switch', 'true', '是否允许项目管理员创建私有namespace'),
|
||||
('configView.memberOnly.envs', 'dev', '只对项目成员显示配置信息的环境列表,多个env以英文逗号分隔'),
|
||||
('apollo.portal.meta.servers', '{}', '各环境Meta Service列表');
|
||||
|
||||
INSERT INTO `Users` (`Username`, `Password`, `UserDisplayName`, `Email`, `Enabled`)
|
||||
VALUES
|
||||
('apollo', '$2a$10$7r20uS.BQ9uBpf3Baj3uQOZvMVvB1RN3PYoKE94gtz2.WAOuiiwXS', 'apollo', 'apollo@acme.com', 1);
|
||||
|
||||
INSERT INTO `Authorities` (`Username`, `Authority`) VALUES ('apollo', 'ROLE_user');
|
||||
|
||||
# Sample Data
|
||||
# ------------------------------------------------------------
|
||||
INSERT INTO `App` (`AppId`, `Name`, `OrgId`, `OrgName`, `OwnerName`, `OwnerEmail`)
|
||||
VALUES
|
||||
('SampleApp', 'Sample App', 'TEST1', '样例部门1', 'apollo', 'apollo@acme.com');
|
||||
|
||||
INSERT INTO `AppNamespace` (`Name`, `AppId`, `Format`, `IsPublic`, `Comment`)
|
||||
VALUES
|
||||
('application', 'SampleApp', 'properties', 0, 'default app namespace');
|
||||
|
||||
INSERT INTO `Permission` (`Id`, `PermissionType`, `TargetId`)
|
||||
VALUES
|
||||
(1, 'CreateCluster', 'SampleApp'),
|
||||
(2, 'CreateNamespace', 'SampleApp'),
|
||||
(3, 'AssignRole', 'SampleApp'),
|
||||
(4, 'ModifyNamespace', 'SampleApp+application'),
|
||||
(5, 'ReleaseNamespace', 'SampleApp+application');
|
||||
|
||||
INSERT INTO `Role` (`Id`, `RoleName`)
|
||||
VALUES
|
||||
(1, 'Master+SampleApp'),
|
||||
(2, 'ModifyNamespace+SampleApp+application'),
|
||||
(3, 'ReleaseNamespace+SampleApp+application');
|
||||
|
||||
INSERT INTO `RolePermission` (`RoleId`, `PermissionId`)
|
||||
VALUES
|
||||
(1, 1),
|
||||
(1, 2),
|
||||
(1, 3),
|
||||
(2, 4),
|
||||
(3, 5);
|
||||
|
||||
INSERT INTO `UserRole` (`UserId`, `RoleId`)
|
||||
VALUES
|
||||
('apollo', 1),
|
||||
('apollo', 2),
|
||||
('apollo', 3);
|
||||
|
||||
-- spring session (https://github.com/spring-projects/spring-session/blob/faee8f1bdb8822a5653a81eba838dddf224d92d6/spring-session-jdbc/src/main/resources/org/springframework/session/jdbc/schema-mysql.sql)
|
||||
CREATE TABLE SPRING_SESSION (
|
||||
PRIMARY_ID CHAR(36) NOT NULL,
|
||||
SESSION_ID CHAR(36) NOT NULL,
|
||||
CREATION_TIME BIGINT NOT NULL,
|
||||
LAST_ACCESS_TIME BIGINT NOT NULL,
|
||||
MAX_INACTIVE_INTERVAL INT NOT NULL,
|
||||
EXPIRY_TIME BIGINT NOT NULL,
|
||||
PRINCIPAL_NAME VARCHAR(100),
|
||||
CONSTRAINT SPRING_SESSION_PK PRIMARY KEY (PRIMARY_ID)
|
||||
) ENGINE=InnoDB ROW_FORMAT=DYNAMIC;
|
||||
|
||||
CREATE UNIQUE INDEX SPRING_SESSION_IX1 ON SPRING_SESSION (SESSION_ID);
|
||||
CREATE INDEX SPRING_SESSION_IX2 ON SPRING_SESSION (EXPIRY_TIME);
|
||||
CREATE INDEX SPRING_SESSION_IX3 ON SPRING_SESSION (PRINCIPAL_NAME);
|
||||
|
||||
CREATE TABLE SPRING_SESSION_ATTRIBUTES (
|
||||
SESSION_PRIMARY_ID CHAR(36) NOT NULL,
|
||||
ATTRIBUTE_NAME VARCHAR(200) NOT NULL,
|
||||
ATTRIBUTE_BYTES BLOB NOT NULL,
|
||||
CONSTRAINT SPRING_SESSION_ATTRIBUTES_PK PRIMARY KEY (SESSION_PRIMARY_ID, ATTRIBUTE_NAME),
|
||||
CONSTRAINT SPRING_SESSION_ATTRIBUTES_FK FOREIGN KEY (SESSION_PRIMARY_ID) REFERENCES SPRING_SESSION(PRIMARY_ID) ON DELETE CASCADE
|
||||
) ENGINE=InnoDB ROW_FORMAT=DYNAMIC;
|
||||
|
||||
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
|
||||
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
|
||||
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
|
||||
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
||||
300
.github/workflows/ci-main.yml
vendored
Normal file
300
.github/workflows/ci-main.yml
vendored
Normal file
@ -0,0 +1,300 @@
|
||||
# The main codes build and unit testing running workflow.
|
||||
name: GoFrame Main CI
|
||||
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- develop
|
||||
- personal/**
|
||||
- feature/**
|
||||
- enhance/**
|
||||
- fix/**
|
||||
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
- develop
|
||||
- personal/**
|
||||
- feature/**
|
||||
- enhance/**
|
||||
- fix/**
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
debug:
|
||||
type: boolean
|
||||
description: 'Enable tmate Debug'
|
||||
required: false
|
||||
default: false
|
||||
|
||||
# This allows a subsequently queued workflow run to interrupt previous runs
|
||||
concurrency:
|
||||
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
|
||||
cancel-in-progress: true
|
||||
|
||||
env:
|
||||
TZ: "Asia/Shanghai"
|
||||
# for unit testing cases of some components that only execute on the latest go version.
|
||||
LATEST_GO_VERSION: "1.25"
|
||||
|
||||
jobs:
|
||||
code-test:
|
||||
strategy:
|
||||
matrix:
|
||||
# 🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥
|
||||
# When adding new go version to the list, make sure:
|
||||
# 1. Update the `LATEST_GO_VERSION` env variable.
|
||||
# 🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥
|
||||
go-version: [ "1.23", "1.24", "1.25" ]
|
||||
goarch: [ "386", "amd64" ]
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
# Service containers to run with `code-test`
|
||||
services:
|
||||
# Etcd service.
|
||||
# docker run -p 2379:2379 -e ALLOW_NONE_AUTHENTICATION=yes bitnamilegacy/etcd:3.4.24
|
||||
etcd:
|
||||
image: bitnamilegacy/etcd:3.4.24
|
||||
env:
|
||||
ALLOW_NONE_AUTHENTICATION: yes
|
||||
ports:
|
||||
- 2379:2379
|
||||
|
||||
# Redis backend server.
|
||||
redis:
|
||||
image : redis:7.0
|
||||
options: >-
|
||||
--health-cmd "redis-cli ping"
|
||||
--health-interval 10s
|
||||
--health-timeout 5s
|
||||
--health-retries 5
|
||||
ports:
|
||||
# Maps tcp port 6379 on service container to the host
|
||||
- 6379:6379
|
||||
|
||||
# MySQL backend server.
|
||||
# docker run \
|
||||
# -p 3306:3306 \
|
||||
# -e MYSQL_DATABASE=test \
|
||||
# -e MYSQL_ROOT_PASSWORD=12345678 \
|
||||
# mysql:5.7
|
||||
mysql:
|
||||
image: mysql:5.7
|
||||
env:
|
||||
MYSQL_DATABASE : test
|
||||
MYSQL_ROOT_PASSWORD: 12345678
|
||||
ports:
|
||||
- 3306:3306
|
||||
|
||||
# MariaDb backend server.
|
||||
# docker run \
|
||||
# -p 3307:3306 \
|
||||
# -e MYSQL_DATABASE=test \
|
||||
# -e MYSQL_ROOT_PASSWORD=12345678 \
|
||||
# mariadb:11.4
|
||||
mariadb:
|
||||
image: mariadb:11.4
|
||||
env:
|
||||
MARIADB_DATABASE: test
|
||||
MARIADB_ROOT_PASSWORD: 12345678
|
||||
ports:
|
||||
- 3307:3306
|
||||
|
||||
# PostgreSQL backend server.
|
||||
# docker run \
|
||||
# -p 5432:5432 \
|
||||
# -e POSTGRES_PASSWORD=12345678 \
|
||||
# -e POSTGRES_USER=postgres \
|
||||
# -e POSTGRES_DB=test \
|
||||
# -v postgres:/Users/john/Temp/postgresql/data \
|
||||
# postgres:17-alpine
|
||||
postgres:
|
||||
image: postgres:17-alpine
|
||||
env:
|
||||
POSTGRES_PASSWORD: 12345678
|
||||
POSTGRES_USER: postgres
|
||||
POSTGRES_DB: test
|
||||
TZ: Asia/Shanghai
|
||||
ports:
|
||||
- 5432:5432
|
||||
# Set health checks to wait until postgres has started
|
||||
options: >-
|
||||
--health-cmd pg_isready
|
||||
--health-interval 10s
|
||||
--health-timeout 5s
|
||||
--health-retries 5
|
||||
|
||||
# MSSQL backend server.
|
||||
# docker run \
|
||||
# -p 1433:1433 \
|
||||
# -e ACCEPT_EULA=Y \
|
||||
# -e SA_PASSWORD=LoremIpsum86 \
|
||||
# -e MSSQL_USER=root \
|
||||
# -e MSSQL_PASSWORD=LoremIpsum86 \
|
||||
# mcr.microsoft.com/mssql/server:2022-latest
|
||||
mssql:
|
||||
image: mcr.microsoft.com/mssql/server:2022-latest
|
||||
env:
|
||||
TZ: Asia/Shanghai
|
||||
ACCEPT_EULA: Y
|
||||
MSSQL_SA_PASSWORD: LoremIpsum86
|
||||
ports:
|
||||
- 1433:1433
|
||||
options: >-
|
||||
--health-cmd="/opt/mssql-tools18/bin/sqlcmd -S localhost -U sa -P ${MSSQL_SA_PASSWORD} -N -C -l 30 -Q \"SELECT 1\" || exit 1"
|
||||
--health-start-period 10s
|
||||
--health-interval 10s
|
||||
--health-timeout 5s
|
||||
--health-retries 10
|
||||
|
||||
# ClickHouse backend server.
|
||||
# docker run \
|
||||
# -p 9000:9000 -p 8123:8123 -p 9001:9001 \
|
||||
# clickhouse/clickhouse-server:24.11.1.2557-alpine
|
||||
clickhouse-server:
|
||||
image: clickhouse/clickhouse-server:24.11.1.2557-alpine
|
||||
ports:
|
||||
- 9000:9000
|
||||
- 8123:8123
|
||||
- 9001:9001
|
||||
|
||||
# Polaris backend server.
|
||||
# docker run \
|
||||
# -p 8090:8090 -p 8091:8091 -p 8093:8093 -p 9090:9090 -p 9091:9091 \
|
||||
# polarismesh/polaris-standalone:v1.17.2
|
||||
polaris:
|
||||
image: polarismesh/polaris-standalone:v1.17.2
|
||||
ports:
|
||||
- 8090:8090
|
||||
- 8091:8091
|
||||
- 8093:8093
|
||||
- 9090:9090
|
||||
- 9091:9091
|
||||
|
||||
# Oracle 11g server.
|
||||
# docker run \
|
||||
# -e ORACLE_ALLOW_REMOTE=true \
|
||||
# -e ORACLE_SID=XE \
|
||||
# -e ORACLE_DB_USER_NAME=system \
|
||||
# -e ORACLE_DB_PASSWORD=oracle \
|
||||
# -p 1521:1521 \
|
||||
# loads/oracle-xe-11g-r2:11.2.0
|
||||
oracle-server:
|
||||
image: loads/oracle-xe-11g-r2:11.2.0
|
||||
env:
|
||||
ORACLE_ALLOW_REMOTE: true
|
||||
ORACLE_SID: XE
|
||||
ORACLE_DB_USER_NAME: system
|
||||
ORACLE_DB_PASSWORD: oracle
|
||||
ports:
|
||||
- 1521:1521
|
||||
|
||||
# dm8 server
|
||||
# docker run -p 5236:5236 loads/dm:v8.1.2.128_ent_x86_64_ctm_pack4
|
||||
dm-server:
|
||||
image: loads/dm:v8.1.2.128_ent_x86_64_ctm_pack4
|
||||
ports:
|
||||
- 5236:5236
|
||||
|
||||
# openGauss server
|
||||
# docker run --privileged=true -e GS_PASSWORD=UTpass@1234 -p 9950:5432 opengauss/opengauss:7.0.0-RC1.B023
|
||||
gaussdb:
|
||||
image: opengauss/opengauss:7.0.0-RC1.B023
|
||||
env:
|
||||
GS_PASSWORD: UTpass@1234
|
||||
TZ: Asia/Shanghai
|
||||
ports:
|
||||
- 9950:5432
|
||||
|
||||
|
||||
zookeeper:
|
||||
image: zookeeper:3.8
|
||||
ports:
|
||||
- 2181:2181
|
||||
|
||||
steps:
|
||||
# TODO: szenius/set-timezone update to node16
|
||||
# sudo ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
|
||||
- name: Setup Timezone
|
||||
uses: szenius/set-timezone@v2.0
|
||||
with:
|
||||
timezoneLinux: "Asia/Shanghai"
|
||||
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v5
|
||||
|
||||
- name: Setup tmate Session
|
||||
uses: mxschmitt/action-tmate@v3
|
||||
if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug }}
|
||||
with:
|
||||
detached: true
|
||||
limit-access-to-actor: false
|
||||
|
||||
- name: Free Disk Space
|
||||
run: |
|
||||
df -h /
|
||||
sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/hostedtoolcache/CodeQL /opt/hostedtoolcache/Python || true
|
||||
df -h /
|
||||
|
||||
- name: Start Apollo Containers
|
||||
run: docker compose -f ".github/workflows/apollo/docker-compose.yml" up -d --build
|
||||
|
||||
- name: Start Nacos Containers
|
||||
run: docker compose -f ".github/workflows/nacos/docker-compose.yml" up -d --build
|
||||
|
||||
- name: Start Redis Cluster Containers
|
||||
run: docker compose -f ".github/workflows/redis/docker-compose.yml" up -d --build
|
||||
|
||||
- name: Start Consul Containers
|
||||
run: docker compose -f ".github/workflows/consul/docker-compose.yml" up -d --build
|
||||
|
||||
- name: Setup Golang ${{ matrix.go-version }}
|
||||
uses: actions/setup-go@v5
|
||||
with:
|
||||
go-version: ${{ matrix.go-version }}
|
||||
cache-dependency-path: '**/go.sum'
|
||||
|
||||
- name: Install Protoc
|
||||
uses: arduino/setup-protoc@v3
|
||||
with:
|
||||
version: "31.x"
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Install the protocol compiler plugins for Go
|
||||
run: |
|
||||
go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
|
||||
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
|
||||
export PATH="$PATH:$(go env GOPATH)/bin"
|
||||
|
||||
- name: Before Script
|
||||
run: bash .github/workflows/scripts/before_script.sh
|
||||
|
||||
- name: Build & Test
|
||||
if: ${{ (github.event_name == 'push' && github.ref != 'refs/heads/master') || github.event_name == 'pull_request' }}
|
||||
run: bash .github/workflows/scripts/ci-main.sh
|
||||
|
||||
- name: Build & Test & Coverage
|
||||
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
|
||||
run: bash .github/workflows/scripts/ci-main.sh coverage
|
||||
|
||||
- name: Stop Redis Cluster Containers
|
||||
run: docker compose -f ".github/workflows/redis/docker-compose.yml" down
|
||||
|
||||
- name: Stop Apollo Containers
|
||||
run: docker compose -f ".github/workflows/apollo/docker-compose.yml" down
|
||||
|
||||
- name: Stop Nacos Containers
|
||||
run: docker compose -f ".github/workflows/nacos/docker-compose.yml" down
|
||||
|
||||
- name: Stop Consul Containers
|
||||
run: docker compose -f ".github/workflows/consul/docker-compose.yml" down
|
||||
|
||||
- name: Report Coverage
|
||||
uses: codecov/codecov-action@v4
|
||||
# Only report coverage on the latest go version
|
||||
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' && matrix.go-version == env.LATEST_GO_VERSION }}
|
||||
with:
|
||||
flags: go-${{ matrix.go-version }}-${{ matrix.goarch }}
|
||||
token: ${{ secrets.CODECOV_TOKEN }}
|
||||
72
.github/workflows/ci-sub.yml
vendored
Normal file
72
.github/workflows/ci-sub.yml
vendored
Normal file
@ -0,0 +1,72 @@
|
||||
# The sub codes build and unit testing running workflow.
|
||||
# It maintains the ci of unimportant packages.
|
||||
name: GoFrame Sub CI
|
||||
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- develop
|
||||
- personal/**
|
||||
- feature/**
|
||||
- enhance/**
|
||||
- fix/**
|
||||
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
- develop
|
||||
- personal/**
|
||||
- feature/**
|
||||
- enhance/**
|
||||
- fix/**
|
||||
|
||||
# This allows a subsequently queued workflow run to interrupt previous runs
|
||||
concurrency:
|
||||
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
|
||||
cancel-in-progress: true
|
||||
|
||||
env:
|
||||
TZ: "Asia/Shanghai"
|
||||
# for unit testing cases of some components that only execute on the latest go version.
|
||||
LATEST_GO_VERSION: "1.25"
|
||||
|
||||
jobs:
|
||||
code-test:
|
||||
strategy:
|
||||
matrix:
|
||||
# 🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥
|
||||
# When adding new go version to the list, make sure:
|
||||
# 1. Update the `LATEST_GO_VERSION` env variable.
|
||||
# 🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥
|
||||
go-version: [ "1.23", "1.24", "1.25" ]
|
||||
goarch: [ "386", "amd64" ]
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Setup Timezone
|
||||
uses: szenius/set-timezone@v2.0
|
||||
with:
|
||||
timezoneLinux: "Asia/Shanghai"
|
||||
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v5
|
||||
|
||||
- name: Start Minikube
|
||||
uses: medyagh/setup-minikube@master
|
||||
|
||||
- name: Setup Golang ${{ matrix.go-version }}
|
||||
uses: actions/setup-go@v5
|
||||
with:
|
||||
go-version: ${{ matrix.go-version }}
|
||||
cache-dependency-path: '**/go.sum'
|
||||
|
||||
- name: Before Script
|
||||
run: bash .github/workflows/scripts/before_script.sh
|
||||
|
||||
- name: Build & Test
|
||||
run: bash .github/workflows/scripts/ci-sub.sh
|
||||
|
||||
|
||||
100
.github/workflows/codeql.yml
vendored
Normal file
100
.github/workflows/codeql.yml
vendored
Normal file
@ -0,0 +1,100 @@
|
||||
# For most projects, this workflow file will not need changing; you simply need
|
||||
# to commit it to your repository.
|
||||
#
|
||||
# You may wish to alter this file to override the set of languages analyzed,
|
||||
# or to provide custom queries or build logic.
|
||||
#
|
||||
# ******** NOTE ********
|
||||
# We have attempted to detect the languages in your repository. Please check
|
||||
# the `language` matrix defined below to confirm you have the correct set of
|
||||
# supported CodeQL languages.
|
||||
#
|
||||
name: "CodeQL Advanced"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "master", "develop" ]
|
||||
pull_request:
|
||||
branches: [ "master", "develop" ]
|
||||
schedule:
|
||||
- cron: '0 21 * * *'
|
||||
|
||||
jobs:
|
||||
analyze:
|
||||
name: Analyze (${{ matrix.language }})
|
||||
# Runner size impacts CodeQL analysis time. To learn more, please see:
|
||||
# - https://gh.io/recommended-hardware-resources-for-running-codeql
|
||||
# - https://gh.io/supported-runners-and-hardware-resources
|
||||
# - https://gh.io/using-larger-runners (GitHub.com only)
|
||||
# Consider using larger runners or machines with greater resources for possible analysis time improvements.
|
||||
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
|
||||
permissions:
|
||||
# required for all workflows
|
||||
security-events: write
|
||||
|
||||
# required to fetch internal or private CodeQL packs
|
||||
packages: read
|
||||
|
||||
# only required for workflows in private repositories
|
||||
actions: read
|
||||
contents: read
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- language: actions
|
||||
build-mode: none
|
||||
- language: go
|
||||
build-mode: autobuild
|
||||
# CodeQL supports the following values keywords for 'language': 'actions', 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'rust', 'swift'
|
||||
# Use `c-cpp` to analyze code written in C, C++ or both
|
||||
# Use 'java-kotlin' to analyze code written in Java, Kotlin or both
|
||||
# Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both
|
||||
# To learn more about changing the languages that are analyzed or customizing the build mode for your analysis,
|
||||
# see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning.
|
||||
# If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how
|
||||
# your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
# Add any setup steps before running the `github/codeql-action/init` action.
|
||||
# This includes steps like installing compilers or runtimes (`actions/setup-node`
|
||||
# or others). This is typically only required for manual builds.
|
||||
# - name: Setup runtime (example)
|
||||
# uses: actions/setup-example@v1
|
||||
|
||||
# Initializes the CodeQL tools for scanning.
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@v3
|
||||
with:
|
||||
languages: ${{ matrix.language }}
|
||||
build-mode: ${{ matrix.build-mode }}
|
||||
# If you wish to specify custom queries, you can do so here or in a config file.
|
||||
# By default, queries listed here will override any specified in a config file.
|
||||
# Prefix the list here with "+" to use these queries and those in the config file.
|
||||
|
||||
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
|
||||
# queries: security-extended,security-and-quality
|
||||
|
||||
# If the analyze step fails for one of the languages you are analyzing with
|
||||
# "We were unable to automatically build your code", modify the matrix above
|
||||
# to set the build mode to "manual" for that language. Then modify this step
|
||||
# to build your code.
|
||||
# ℹ️ Command-line programs to run using the OS shell.
|
||||
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
|
||||
- if: matrix.build-mode == 'manual'
|
||||
shell: bash
|
||||
run: |
|
||||
echo 'If you are using a "manual" build mode for one or more of the' \
|
||||
'languages you are analyzing, replace this with the commands to build' \
|
||||
'your code, for example:'
|
||||
echo ' make bootstrap'
|
||||
echo ' make release'
|
||||
exit 1
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@v3
|
||||
with:
|
||||
category: "/language:${{matrix.language}}"
|
||||
7
.github/workflows/consul/client.json
vendored
Normal file
7
.github/workflows/consul/client.json
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
{
|
||||
"node_name": "consul-client",
|
||||
"data_dir": "/consul/data",
|
||||
"retry_join":[
|
||||
"consul-server"
|
||||
]
|
||||
}
|
||||
31
.github/workflows/consul/docker-compose.yml
vendored
Normal file
31
.github/workflows/consul/docker-compose.yml
vendored
Normal file
@ -0,0 +1,31 @@
|
||||
version: '3.7'
|
||||
|
||||
services:
|
||||
|
||||
consul-server:
|
||||
image: consul:1.15
|
||||
container_name: consul-server
|
||||
restart: always
|
||||
volumes:
|
||||
- ./server.json:/consul/config/server.json:ro
|
||||
networks:
|
||||
- consul
|
||||
ports:
|
||||
- "8500:8500"
|
||||
- "8600:8600/tcp"
|
||||
- "8600:8600/udp"
|
||||
command: "agent"
|
||||
|
||||
consul-client:
|
||||
image: consul:1.15
|
||||
container_name: consul-client
|
||||
restart: always
|
||||
volumes:
|
||||
- ./client.json:/consul/config/client.json:ro
|
||||
networks:
|
||||
- consul
|
||||
command: "agent"
|
||||
|
||||
networks:
|
||||
consul:
|
||||
driver: bridge
|
||||
12
.github/workflows/consul/server.json
vendored
Normal file
12
.github/workflows/consul/server.json
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
{
|
||||
"node_name": "consul-server",
|
||||
"server": true,
|
||||
"bootstrap" : true,
|
||||
"ui_config": {
|
||||
"enabled" : true
|
||||
},
|
||||
"data_dir": "/consul/data",
|
||||
"addresses": {
|
||||
"http" : "0.0.0.0"
|
||||
}
|
||||
}
|
||||
61
.github/workflows/format-code-on-push.yml
vendored
Normal file
61
.github/workflows/format-code-on-push.yml
vendored
Normal file
@ -0,0 +1,61 @@
|
||||
name: Format Code on Push
|
||||
|
||||
on:
|
||||
push
|
||||
|
||||
jobs:
|
||||
format-code:
|
||||
strategy:
|
||||
matrix:
|
||||
go-version: [ 'stable' ]
|
||||
name: format-code-by-gci
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v5
|
||||
- name: Setup Golang ${{ matrix.go-version }}
|
||||
uses: actions/setup-go@v5
|
||||
with:
|
||||
go-version: ${{ matrix.go-version }}
|
||||
- name: Install gci
|
||||
run: go install github.com/daixiang0/gci@latest
|
||||
- name: Run gci
|
||||
run: |
|
||||
gci write --custom-order \
|
||||
--skip-generated \
|
||||
--skip-vendor \
|
||||
-s standard \
|
||||
-s blank \
|
||||
-s default \
|
||||
-s dot \
|
||||
-s "prefix(github.com/gogf/gf/v2)" \
|
||||
-s "prefix(github.com/gogf/gf/cmd)" \
|
||||
-s "prefix(github.com/gogf/gf/contrib)" \
|
||||
-s "prefix(github.com/gogf/gf/example)" \
|
||||
./
|
||||
- name: Check for changes
|
||||
run: |
|
||||
if [[ -n "$(git status --porcelain)" ]]; then
|
||||
echo "HAS_CHANGES=true" >> $GITHUB_ENV
|
||||
else
|
||||
echo "HAS_CHANGES=false" >> $GITHUB_ENV
|
||||
fi
|
||||
- name: Configure Git
|
||||
run: |
|
||||
if [[ "$HAS_CHANGES" == 'true' ]]; then
|
||||
git config --global user.name "github-actions[bot]"
|
||||
git config --global user.email "github-actions[bot]@users.noreply.github.com"
|
||||
else
|
||||
echo "HAS_CHANGES= $HAS_CHANGES "
|
||||
fi
|
||||
- name: Commit and push changes
|
||||
run: |
|
||||
if [[ "$HAS_CHANGES" == 'true' ]]; then
|
||||
git add .
|
||||
git commit -m "Apply gci import order changes"
|
||||
git push origin ${{ github.event.pull_request.head.ref }}
|
||||
else
|
||||
echo "No change to commit push"
|
||||
fi
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
28
.github/workflows/gitee-sync.yml
vendored
Normal file
28
.github/workflows/gitee-sync.yml
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
tags:
|
||||
- "*"
|
||||
|
||||
name: Sync to Gitee
|
||||
jobs:
|
||||
run:
|
||||
name: Run
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout source code
|
||||
uses: actions/checkout@v5
|
||||
- name: Mirror GitHub to Gitee
|
||||
uses: Yikun/hub-mirror-action@v1.4
|
||||
with:
|
||||
src: github/gogf
|
||||
dst: gitee/johng
|
||||
dst_key: ${{ secrets.GITEE_PRIVATE_KEY }}
|
||||
dst_token: ${{ secrets.GITEE_TOKEN }}
|
||||
src_account_type: org
|
||||
dst_account_type: user
|
||||
timeout: 600
|
||||
debug: true
|
||||
force_update: true
|
||||
static_list: "gf"
|
||||
52
.github/workflows/golangci-lint.yml
vendored
Normal file
52
.github/workflows/golangci-lint.yml
vendored
Normal file
@ -0,0 +1,52 @@
|
||||
# Copyright GoFrame Author(https://goframe.org). All Rights Reserved.
|
||||
#
|
||||
# This Source Code Form is subject to the terms of the MIT License.
|
||||
# If a copy of the MIT was not distributed with this file,
|
||||
# You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
name: golangci-lint
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- develop
|
||||
- personal/**
|
||||
- feature/**
|
||||
- enhance/**
|
||||
- fix/**
|
||||
- feat/**
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
- develop
|
||||
- personal/**
|
||||
- feature/**
|
||||
- enhance/**
|
||||
- fix/**
|
||||
- feat/**
|
||||
|
||||
jobs:
|
||||
golang-ci:
|
||||
strategy:
|
||||
matrix:
|
||||
go-version: [ "stable" ]
|
||||
|
||||
name: golang-ci-lint
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Setup Golang ${{ matrix.go-version }}
|
||||
uses: actions/setup-go@v5
|
||||
with:
|
||||
go-version: ${{ matrix.go-version }}
|
||||
- name: golang-ci-lint
|
||||
uses: golangci/golangci-lint-action@v8
|
||||
with:
|
||||
# Required: specify the golangci-lint version without the patch version to always use the latest patch.
|
||||
only-new-issues: true
|
||||
skip-cache: true
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
args: --config=.golangci.yml -v
|
||||
28
.github/workflows/issue-check-inactive.yml
vendored
Normal file
28
.github/workflows/issue-check-inactive.yml
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
# Rule description: Execute the ISSUE once a day at 3 a.m. (GMT+8) and set the non-bug issue that has not been active in the last 7 days to inactive
|
||||
name: Issue Check Inactive
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: "0 19 * * *"
|
||||
|
||||
env: # Set environment variables
|
||||
TZ: Asia/Shanghai #Time zone (setting the time zone allows the 'Last Updated' on the page to use the time zone)
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
issue-check-inactive:
|
||||
permissions:
|
||||
issues: write # for actions-cool/issues-helper to update issues
|
||||
# pull-requests: write # for actions-cool/issues-helper to update PRs
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: check-inactive
|
||||
uses: actions-cool/issues-helper@v3
|
||||
with:
|
||||
actions: 'check-inactive'
|
||||
inactive-label: 'inactive'
|
||||
inactive-day: 30
|
||||
issue-state: open
|
||||
exclude-labels: 'bug,planned,$exclude-empty'
|
||||
23
.github/workflows/issue-close-inactive.yml
vendored
Normal file
23
.github/workflows/issue-close-inactive.yml
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
# RULE DESCRIPTION: EXECUTED ONCE A DAY AT 4 A.M. (GMT+8) TO CLOSE NON-BUG ISSUES THAT HAVE NOT BEEN ACTIVE IN THE LAST 30 DAYS
|
||||
name: Issue Close Inactive
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: "0 20 * * *"
|
||||
|
||||
env: # Set environment variables
|
||||
TZ: Asia/Shanghai #Time zone (setting the time zone allows the 'Last Updated' on the page to use the time zone)
|
||||
|
||||
jobs:
|
||||
close-issues:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: need close
|
||||
uses: actions-cool/issues-helper@v3
|
||||
with:
|
||||
actions: "close-issues"
|
||||
# token: ${{ secrets.GF_TOKEN }}
|
||||
labels: 'inactive'
|
||||
inactive-day: 30
|
||||
exclude-labels: 'bug,$exclude-empty'
|
||||
close-reason: 'not active'
|
||||
25
.github/workflows/issue-labeled.yml
vendored
Normal file
25
.github/workflows/issue-labeled.yml
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
## Rule description: Add comments when an issue is marked as help wanted
|
||||
|
||||
name: Issue Labeled
|
||||
|
||||
on:
|
||||
issues:
|
||||
types: [labeled]
|
||||
|
||||
env: # Set environment variables
|
||||
TZ: Asia/Shanghai # Time zone (setting the time zone allows the 'Last Updated' on the page to use the time zone)
|
||||
|
||||
jobs:
|
||||
reply-labeled:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: contribution welcome
|
||||
if: github.event.label.name == 'help wanted'
|
||||
uses: actions-cool/issues-helper@v3
|
||||
with:
|
||||
actions: "create-comment, remove-labels"
|
||||
# token: ${{ secrets.GF_TOKEN }}
|
||||
issue-number: ${{ github.event.issue.number }}
|
||||
body: |
|
||||
Hello @${{ github.event.issue.user.login }}. We like your proposal/feedback and would appreciate a contribution via a Pull Request by you or another community member. We thank you in advance for your contribution and are looking forward to reviewing it!
|
||||
你好 @${{ github.event.issue.user.login }}。我们喜欢您的提案/反馈,并希望您或其他社区成员通过拉取请求做出贡献。我们提前感谢您的贡献,并期待对其进行审查。
|
||||
29
.github/workflows/issue-remove-inactive.yml
vendored
Normal file
29
.github/workflows/issue-remove-inactive.yml
vendored
Normal file
@ -0,0 +1,29 @@
|
||||
# Rule description: If an issue author updates or comments on an issue while it is not active and has not been closed, the inactive tag will be removed
|
||||
name: Issue Remove Inactive
|
||||
|
||||
on:
|
||||
issues:
|
||||
types: [edited]
|
||||
issue_comment:
|
||||
types: [created, edited]
|
||||
|
||||
env: # Set environment variables
|
||||
TZ: Asia/Shanghai #Time zone (setting the time zone allows the 'Last Updated' on the page to use the time zone)
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
issue-remove-inactive:
|
||||
permissions:
|
||||
issues: write # for actions-cool/issues-helper to update issues
|
||||
# pull-requests: write # for actions-cool/issues-helper to update PRs
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: remove inactive
|
||||
if: github.event.issue.state == 'open'
|
||||
uses: actions-cool/issues-helper@v3
|
||||
with:
|
||||
actions: 'remove-labels'
|
||||
issue-number: ${{ github.event.issue.number }}
|
||||
labels: 'inactive'
|
||||
29
.github/workflows/issue-remove-need-more-details.yml
vendored
Normal file
29
.github/workflows/issue-remove-need-more-details.yml
vendored
Normal file
@ -0,0 +1,29 @@
|
||||
# Rule Description: For issues that need more details and are not yet closed, remove the "need more details" tag after the issue author comments
|
||||
name: Issue Remove Need More Details
|
||||
|
||||
on:
|
||||
issues:
|
||||
types: [edited]
|
||||
issue_comment:
|
||||
types: [created, edited]
|
||||
|
||||
env: # Set environment variables
|
||||
TZ: Asia/Shanghai #Time zone (setting the time zone allows the 'Last Updated' on the page to use the time zone)
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
issue-remove-need-more-details:
|
||||
permissions:
|
||||
issues: write # for actions-cool/issues-helper to update issues
|
||||
# pull-requests: write # for actions-cool/issues-helper to update PRs
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: remove need more details
|
||||
if: github.event.issue.state == 'open' && github.actor == github.event.issue.user.login
|
||||
uses: actions-cool/issues-helper@v3
|
||||
with:
|
||||
actions: 'remove-labels'
|
||||
issue-number: ${{ github.event.issue.number }}
|
||||
labels: 'need more details'
|
||||
19
.github/workflows/issue-translator.yml
vendored
Normal file
19
.github/workflows/issue-translator.yml
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
# https://github.com/usthe/issues-translate-action
|
||||
name: 'Issue Translator'
|
||||
on:
|
||||
issue_comment:
|
||||
types: [created]
|
||||
issues:
|
||||
types: [opened]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: usthe/issues-translate-action@v2.7
|
||||
with:
|
||||
IS_MODIFY_TITLE: true
|
||||
# not require, default false. Decide whether to modify the issue title
|
||||
# if true, the robot account @Issues-translate-bot must have modification permissions,
|
||||
# invite @Issues-translate-bot to your project or use your custom bot.
|
||||
CUSTOM_BOT_NOTE: Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑🤝🧑👫🧑🏿🤝🧑🏻👩🏾🤝👨🏿👬🏿
|
||||
24
.github/workflows/nacos/docker-compose.yml
vendored
Normal file
24
.github/workflows/nacos/docker-compose.yml
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
version: "3.8"
|
||||
|
||||
services:
|
||||
nacos:
|
||||
image: nacos/nacos-server:v2.1.2
|
||||
container_name: nacos
|
||||
env_file:
|
||||
- ./env/nacos.env
|
||||
ports:
|
||||
- "8848:8848"
|
||||
- "9848:9848"
|
||||
- "9555:9555"
|
||||
healthcheck:
|
||||
test: [ "CMD", "curl" ,"http://localhost:8848/nacos" ]
|
||||
interval: 5s
|
||||
timeout: 3s
|
||||
retries: 10
|
||||
|
||||
initializer:
|
||||
image: alpine/curl:latest
|
||||
depends_on:
|
||||
nacos:
|
||||
condition: service_healthy
|
||||
command: [ "sh", "-c", "curl -X POST 'http://nacos:8848/nacos/v1/cs/configs?dataId=config.toml&group=test&content=%5Bserver%5D%0A%09address%3D%22%3A8000%22'" ]
|
||||
2
.github/workflows/nacos/env/nacos.env
vendored
Normal file
2
.github/workflows/nacos/env/nacos.env
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
PREFER_HOST_MODE=hostname
|
||||
MODE=standalone
|
||||
95
.github/workflows/redis/docker-compose.yml
vendored
Normal file
95
.github/workflows/redis/docker-compose.yml
vendored
Normal file
@ -0,0 +1,95 @@
|
||||
version: "2"
|
||||
|
||||
services:
|
||||
redis-master:
|
||||
container_name: redis-master
|
||||
image: "loads/redis:7.0-sentinel"
|
||||
environment:
|
||||
- REDIS_REPLICATION_MODE=master
|
||||
- REDIS_PASSWORD=111111
|
||||
ports:
|
||||
- 6380:6379
|
||||
|
||||
redis-slave1:
|
||||
container_name: redis-slave1
|
||||
image: "loads/redis:7.0-sentinel"
|
||||
environment:
|
||||
- REDIS_REPLICATION_MODE=slave
|
||||
- REDIS_MASTER_HOST=redis-master
|
||||
- REDIS_MASTER_PASSWORD=111111
|
||||
- REDIS_PASSWORD=111111
|
||||
ports:
|
||||
- 6381:6379
|
||||
depends_on:
|
||||
- redis-master
|
||||
links:
|
||||
- redis-master
|
||||
|
||||
redis-slave2:
|
||||
container_name: redis-slave2
|
||||
image: "loads/redis:7.0-sentinel"
|
||||
environment:
|
||||
- REDIS_REPLICATION_MODE=slave
|
||||
- REDIS_MASTER_HOST=redis-master
|
||||
- REDIS_MASTER_PASSWORD=111111
|
||||
- REDIS_PASSWORD=111111
|
||||
ports:
|
||||
- 6382:6379
|
||||
depends_on:
|
||||
- redis-master
|
||||
links:
|
||||
- redis-master
|
||||
|
||||
redis-sentinel-1:
|
||||
container_name: redis-sentinel-1
|
||||
image: "loads/redis-sentinel:7.0"
|
||||
environment:
|
||||
- REDIS_MASTER_HOST=redis-master
|
||||
- REDIS_MASTER_PORT_NUMBER=6379
|
||||
- REDIS_MASTER_PASSWORD=111111
|
||||
depends_on:
|
||||
- redis-master
|
||||
- redis-slave1
|
||||
- redis-slave2
|
||||
ports:
|
||||
- 26379:26379
|
||||
links:
|
||||
- redis-master
|
||||
- redis-slave1
|
||||
- redis-slave2
|
||||
|
||||
redis-sentinel-2:
|
||||
container_name: redis-sentinel-2
|
||||
image: "loads/redis-sentinel:7.0"
|
||||
environment:
|
||||
- REDIS_MASTER_HOST=redis-master
|
||||
- REDIS_MASTER_PORT_NUMBER=6379
|
||||
- REDIS_MASTER_PASSWORD=111111
|
||||
depends_on:
|
||||
- redis-master
|
||||
- redis-slave1
|
||||
- redis-slave2
|
||||
links:
|
||||
- redis-master
|
||||
- redis-slave1
|
||||
- redis-slave2
|
||||
ports:
|
||||
- 26380:26379
|
||||
|
||||
redis-sentinel-3:
|
||||
container_name: redis-sentinel-3
|
||||
image: "loads/redis-sentinel:7.0"
|
||||
environment:
|
||||
- REDIS_MASTER_HOST=redis-master
|
||||
- REDIS_MASTER_PORT_NUMBER=6379
|
||||
- REDIS_MASTER_PASSWORD=111111
|
||||
depends_on:
|
||||
- redis-master
|
||||
- redis-slave1
|
||||
- redis-slave2
|
||||
ports:
|
||||
- 26381:26379
|
||||
links:
|
||||
- redis-master
|
||||
- redis-slave1
|
||||
- redis-slave2
|
||||
66
.github/workflows/release.yml
vendored
Normal file
66
.github/workflows/release.yml
vendored
Normal file
@ -0,0 +1,66 @@
|
||||
name: GoFrame Release
|
||||
|
||||
on:
|
||||
push:
|
||||
# Sequence of patterns matched against refs/tags
|
||||
tags:
|
||||
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
|
||||
|
||||
env:
|
||||
TZ: Asia/Shanghai
|
||||
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build And Release
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Github Code
|
||||
uses: actions/checkout@v5
|
||||
|
||||
- name: Set Up Golang Environment
|
||||
uses: actions/setup-go@v5
|
||||
with:
|
||||
go-version: 1.25
|
||||
cache: false
|
||||
|
||||
- name: Build CLI Binary
|
||||
run: |
|
||||
echo "Building linux amd64 binary..."
|
||||
cd cmd/gf
|
||||
GOOS=linux GOARCH=amd64 go build main.go
|
||||
chmod +x main
|
||||
./main install -y
|
||||
|
||||
- name: Build CLI Binary For All Platform
|
||||
run: |
|
||||
cd cmd/gf
|
||||
gf build main.go -n gf -a all -s linux,windows,darwin,freebsd,netbsd,openbsd -p temp
|
||||
|
||||
- name: Move Files Before Release
|
||||
run: |
|
||||
cd cmd/gf/temp
|
||||
for OS in *;do for FILE in $OS/*;\
|
||||
do if [[ ${OS} =~ 'windows' ]];\
|
||||
then mv $FILE gf_$OS.exe && rm -rf $OS;\
|
||||
else mv $FILE gf_$OS && rm -rf $OS;\
|
||||
fi;done;done
|
||||
|
||||
- name: Create Github Release
|
||||
id: create_release
|
||||
uses: softprops/action-gh-release@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
tag_name: ${{ github.ref }}
|
||||
name: GoFrame Release ${{ github.ref_name }}
|
||||
draft: false
|
||||
prerelease: false
|
||||
|
||||
- name: Upload Release Asset
|
||||
id: upload-release-asset
|
||||
uses: alexellis/upload-assets@0.4.0
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
asset_paths: '["cmd/gf/temp/gf_*"]'
|
||||
80
.github/workflows/scorecard.yml
vendored
Normal file
80
.github/workflows/scorecard.yml
vendored
Normal file
@ -0,0 +1,80 @@
|
||||
# This workflow uses actions that are not certified by GitHub. They are provided
|
||||
# by a third-party and are governed by separate terms of service, privacy
|
||||
# policy, and support documentation.
|
||||
|
||||
name: Scorecard supply-chain security
|
||||
on:
|
||||
# For Branch-Protection check. Only the default branch is supported. See
|
||||
# https://github.com/ossf/scorecard/blob/main/docs/checks.md#branch-protection
|
||||
branch_protection_rule:
|
||||
# To guarantee Maintained check is occasionally updated. See
|
||||
# https://github.com/ossf/scorecard/blob/main/docs/checks.md#maintained
|
||||
schedule:
|
||||
- cron: '0 21 * * *'
|
||||
push:
|
||||
branches: [ "master" ]
|
||||
pull_request:
|
||||
branches: [ "master" ]
|
||||
|
||||
# Declare default permissions as read only.
|
||||
permissions: read-all
|
||||
|
||||
jobs:
|
||||
analysis:
|
||||
name: Scorecard analysis
|
||||
runs-on: ubuntu-latest
|
||||
# `publish_results: true` only works when run from the default branch. conditional can be removed if disabled.
|
||||
if: github.event.repository.default_branch == github.ref_name || github.event_name == 'pull_request'
|
||||
permissions:
|
||||
# Needed to upload the results to code-scanning dashboard.
|
||||
security-events: write
|
||||
# Needed to publish results and get a badge (see publish_results below).
|
||||
id-token: write
|
||||
# Uncomment the permissions below if installing in a private repository.
|
||||
# contents: read
|
||||
# actions: read
|
||||
|
||||
steps:
|
||||
- name: "Checkout code"
|
||||
uses: actions/checkout@v4.2.2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
- name: "Run analysis"
|
||||
uses: ossf/scorecard-action@v2.4.1
|
||||
with:
|
||||
results_file: results.sarif
|
||||
results_format: sarif
|
||||
# (Optional) "write" PAT token. Uncomment the `repo_token` line below if:
|
||||
# - you want to enable the Branch-Protection check on a *public* repository, or
|
||||
# - you are installing Scorecard on a *private* repository
|
||||
# To create the PAT, follow the steps in https://github.com/ossf/scorecard-action?tab=readme-ov-file#authentication-with-fine-grained-pat-optional.
|
||||
# repo_token: ${{ secrets.SCORECARD_TOKEN }}
|
||||
|
||||
# Public repositories:
|
||||
# - Publish results to OpenSSF REST API for easy access by consumers
|
||||
# - Allows the repository to include the Scorecard badge.
|
||||
# - See https://github.com/ossf/scorecard-action#publishing-results.
|
||||
# For private repositories:
|
||||
# - `publish_results` will always be set to `false`, regardless
|
||||
# of the value entered here.
|
||||
publish_results: true
|
||||
|
||||
# (Optional) Uncomment file_mode if you have a .gitattributes with files marked export-ignore
|
||||
# file_mode: git
|
||||
|
||||
# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
|
||||
# format to the repository Actions tab.
|
||||
- name: "Upload artifact"
|
||||
uses: actions/upload-artifact@v4.6.1
|
||||
with:
|
||||
name: SARIF file
|
||||
path: results.sarif
|
||||
retention-days: 5
|
||||
|
||||
# Upload the results to GitHub's code scanning dashboard (optional).
|
||||
# Commenting out will disable upload of results to your repo's Code Scanning dashboard
|
||||
- name: "Upload to code-scanning"
|
||||
uses: github/codeql-action/upload-sarif@v3
|
||||
with:
|
||||
sarif_file: results.sarif
|
||||
36
.github/workflows/scripts/before_script.sh
vendored
Executable file
36
.github/workflows/scripts/before_script.sh
vendored
Executable file
@ -0,0 +1,36 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Install gci
|
||||
echo "Installing gci..."
|
||||
go install github.com/daixiang0/gci@latest
|
||||
|
||||
# Check if the GCI is installed successfully
|
||||
if ! command -v gci &> /dev/null
|
||||
then
|
||||
echo "gci could not be installed. Please check your Go setup."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Use GCI to format the code
|
||||
echo "Running gci to format code..."
|
||||
gci write \
|
||||
--custom-order \
|
||||
--skip-generated \
|
||||
--skip-vendor \
|
||||
-s standard \
|
||||
-s blank \
|
||||
-s default \
|
||||
-s dot \
|
||||
-s "prefix(github.com/gogf/gf/v2)" \
|
||||
-s "prefix(github.com/gogf/gf/cmd)" \
|
||||
-s "prefix(github.com/gogf/gf/contrib)" \
|
||||
-s "prefix(github.com/gogf/gf/example)" \
|
||||
./
|
||||
|
||||
# Check the code for changes
|
||||
git diff --name-only --exit-code || if [ $? != 0 ]; then echo "Notice: gci check failed, please gci before pr." && exit 1; fi
|
||||
echo "gci check pass."
|
||||
|
||||
# Add the local domain name to `/etc/hosts`
|
||||
echo "Adding local domain to /etc/hosts..."
|
||||
sudo echo "127.0.0.1 local" | sudo tee -a /etc/hosts
|
||||
250
.github/workflows/scripts/ci-main-clean.sh
vendored
Executable file
250
.github/workflows/scripts/ci-main-clean.sh
vendored
Executable file
@ -0,0 +1,250 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
dirpath=$1
|
||||
|
||||
# Extract the base directory name for pattern matching
|
||||
if [ -n "$dirpath" ]; then
|
||||
dirname=$(basename "$dirpath")
|
||||
echo "Cleaning Docker resources for path: $dirpath (pattern: $dirname)"
|
||||
df -h /
|
||||
|
||||
# Process containers and images based on the directory
|
||||
case "$dirname" in
|
||||
# "mysql")
|
||||
# echo "Cleaning mysql resources..."
|
||||
# containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
# if [ -n "$containers" ]; then
|
||||
# echo "Stopping and removing mysql containers..."
|
||||
# docker stop $containers 2>/dev/null || true
|
||||
# docker rm -f $containers 2>/dev/null || true
|
||||
# fi
|
||||
# docker rmi -f $(docker images -q mysql 2>/dev/null) 2>/dev/null || true
|
||||
# ;;
|
||||
"mssql")
|
||||
echo "Cleaning mssql resources..."
|
||||
containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
if [ -n "$containers" ]; then
|
||||
echo "Stopping and removing mssql containers..."
|
||||
docker stop $containers 2>/dev/null || true
|
||||
docker rm -f $containers 2>/dev/null || true
|
||||
fi
|
||||
docker rmi -f $(docker images -q mcr.microsoft.com/mssql/server 2>/dev/null) 2>/dev/null || true
|
||||
;;
|
||||
"pgsql")
|
||||
echo "Cleaning postgres resources..."
|
||||
containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
if [ -n "$containers" ]; then
|
||||
echo "Stopping and removing postgres containers..."
|
||||
docker stop $containers 2>/dev/null || true
|
||||
docker rm -f $containers 2>/dev/null || true
|
||||
fi
|
||||
docker rmi -f $(docker images -q postgres 2>/dev/null) 2>/dev/null || true
|
||||
;;
|
||||
"oracle")
|
||||
echo "Cleaning oracle resources..."
|
||||
containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
if [ -n "$containers" ]; then
|
||||
echo "Stopping and removing oracle containers..."
|
||||
docker stop $containers 2>/dev/null || true
|
||||
docker rm -f $containers 2>/dev/null || true
|
||||
fi
|
||||
docker rmi -f $(docker images -q loads/oracle-xe-11g-r2 2>/dev/null) 2>/dev/null || true
|
||||
;;
|
||||
"dm")
|
||||
echo "Cleaning dm resources..."
|
||||
containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
if [ -n "$containers" ]; then
|
||||
echo "Stopping and removing dm containers..."
|
||||
docker stop $containers 2>/dev/null || true
|
||||
docker rm -f $containers 2>/dev/null || true
|
||||
fi
|
||||
docker rmi -f $(docker images -q loads/dm 2>/dev/null) 2>/dev/null || true
|
||||
;;
|
||||
"clickhouse")
|
||||
echo "Cleaning clickhouse resources..."
|
||||
containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
if [ -n "$containers" ]; then
|
||||
echo "Stopping and removing clickhouse containers..."
|
||||
docker stop $containers 2>/dev/null || true
|
||||
docker rm -f $containers 2>/dev/null || true
|
||||
fi
|
||||
docker rmi -f $(docker images -q clickhouse/clickhouse-server 2>/dev/null) 2>/dev/null || true
|
||||
;;
|
||||
# "redis")
|
||||
# echo "Cleaning redis resources..."
|
||||
# containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
# if [ -n "$containers" ]; then
|
||||
# echo "Stopping and removing redis containers..."
|
||||
# docker stop $containers 2>/dev/null || true
|
||||
# docker rm -f $containers 2>/dev/null || true
|
||||
# fi
|
||||
# docker rmi -f $(docker images -q redis loads/redis loads/redis-sentinel 2>/dev/null) 2>/dev/null || true
|
||||
# ;;
|
||||
"etcd")
|
||||
echo "Cleaning etcd resources..."
|
||||
containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
if [ -n "$containers" ]; then
|
||||
echo "Stopping and removing etcd containers..."
|
||||
docker stop $containers 2>/dev/null || true
|
||||
docker rm -f $containers 2>/dev/null || true
|
||||
fi
|
||||
docker rmi -f $(docker images -q bitnamilegacy/etcd 2>/dev/null) 2>/dev/null || true
|
||||
;;
|
||||
# "consul")
|
||||
# echo "Cleaning consul resources..."
|
||||
# containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
# if [ -n "$containers" ]; then
|
||||
# echo "Stopping and removing consul containers..."
|
||||
# docker stop $containers 2>/dev/null || true
|
||||
# docker rm -f $containers 2>/dev/null || true
|
||||
# fi
|
||||
# docker rmi -f $(docker images -q consul 2>/dev/null) 2>/dev/null || true
|
||||
# ;;
|
||||
# "nacos")
|
||||
# echo "Cleaning nacos resources..."
|
||||
# containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
# if [ -n "$containers" ]; then
|
||||
# echo "Stopping and removing nacos containers..."
|
||||
# docker stop $containers 2>/dev/null || true
|
||||
# docker rm -f $containers 2>/dev/null || true
|
||||
# fi
|
||||
# docker rmi -f $(docker images -q nacos/nacos-server 2>/dev/null) 2>/dev/null || true
|
||||
# ;;
|
||||
# "polaris")
|
||||
# echo "Cleaning polaris resources..."
|
||||
# containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
# if [ -n "$containers" ]; then
|
||||
# echo "Stopping and removing polaris containers..."
|
||||
# docker stop $containers 2>/dev/null || true
|
||||
# docker rm -f $containers 2>/dev/null || true
|
||||
# fi
|
||||
# docker rmi -f $(docker images -q polarismesh/polaris-standalone 2>/dev/null) 2>/dev/null || true
|
||||
# ;;
|
||||
"zookeeper")
|
||||
echo "Cleaning zookeeper resources..."
|
||||
containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
if [ -n "$containers" ]; then
|
||||
echo "Stopping and removing zookeeper containers..."
|
||||
docker stop $containers 2>/dev/null || true
|
||||
docker rm -f $containers 2>/dev/null || true
|
||||
fi
|
||||
docker rmi -f $(docker images -q zookeeper 2>/dev/null) 2>/dev/null || true
|
||||
;;
|
||||
# "apollo")
|
||||
# echo "Cleaning apollo resources..."
|
||||
# containers=$(docker ps -aq --filter "name=$dirname" 2>/dev/null)
|
||||
# if [ -n "$containers" ]; then
|
||||
# echo "Stopping and removing apollo containers..."
|
||||
# docker stop $containers 2>/dev/null || true
|
||||
# docker rm -f $containers 2>/dev/null || true
|
||||
# fi
|
||||
# docker rmi -f $(docker images -q loads/apollo-quick-start 2>/dev/null) 2>/dev/null || true
|
||||
# ;;
|
||||
*)
|
||||
# No matching pattern, skip cleanup
|
||||
echo "No specific Docker cleanup rule for '$dirname', skipping cleanup"
|
||||
;;
|
||||
esac
|
||||
|
||||
# Remove dangling images and volumes to free up space
|
||||
echo "Removing dangling images and unused volumes..."
|
||||
docker image prune -f 2>/dev/null || true
|
||||
docker volume prune -f 2>/dev/null || true
|
||||
|
||||
echo "Docker cleanup completed for $dirname"
|
||||
docker system df
|
||||
df -h /
|
||||
fi
|
||||
|
||||
# df -h /
|
||||
# Filesystem Size Used Avail Use% Mounted on
|
||||
# /dev/root 72G 67G 5.4G 93% /
|
||||
# tmpfs 7.9G 84K 7.9G 1% /dev/shm
|
||||
# tmpfs 3.2G 2.6M 3.2G 1% /run
|
||||
# tmpfs 5.0M 0 5.0M 0% /run/lock
|
||||
# /dev/sdb16 881M 62M 758M 8% /boot
|
||||
# /dev/sdb15 105M 6.2M 99M 6% /boot/efi
|
||||
# /dev/sda1 74G 4.1G 66G 6% /mnt
|
||||
# tmpfs 1.6G 12K 1.6G 1% /run/user/1001
|
||||
|
||||
# runner@runnervmg1sw1:~/work/gf/gf$ docker system df
|
||||
# TYPE TOTAL ACTIVE SIZE RECLAIMABLE
|
||||
# Images 18 11 8.326GB 1.644GB (19%)
|
||||
# Containers 11 11 2.692GB 0B (0%)
|
||||
# Local Volumes 11 8 665.7MB 211.9MB (31%)
|
||||
# Build Cache 0 0 0B 0B
|
||||
|
||||
# runner@runnervmg1sw1:~/work/gf/gf$ docker images
|
||||
# REPOSITORY TAG IMAGE ID CREATED SIZE
|
||||
# alpine/curl latest 99fd43792a61 2 days ago 13.5MB
|
||||
# postgres 17-alpine b6bf692a8125 9 days ago 278MB
|
||||
# zookeeper 3.8 2f26c02b94ca 10 days ago 306MB
|
||||
# mariadb 11.4 063fb6684f96 10 days ago 332MB
|
||||
# mcr.microsoft.com/mssql/server 2022-latest a2fbff321505 4 weeks ago 1.61GB
|
||||
# clickhouse/clickhouse-server 24.11.1.2557-alpine 2eee9fd3ae74 12 months ago 539MB
|
||||
# redis 7.0 7705dd2858c1 18 months ago 109MB
|
||||
# consul 1.15 686495461132 20 months ago 155MB
|
||||
# mysql 5.7 5107333e08a8 23 months ago 501MB
|
||||
# polarismesh/polaris-standalone v1.17.2 b7a8cf0a8438 2 years ago 545MB
|
||||
# bitnamilegacy/etcd 3.4.24 74ae5e205ac5 2 years ago 134MB
|
||||
# nacos/nacos-server v2.1.2 a978644d9246 2 years ago 1.06GB
|
||||
# loads/redis 7.0-sentinel 6f12d40540ba 3 years ago 114MB
|
||||
# loads/dm v8.1.2.128_ent_x86_64_ctm_pack4 ccb727ce9dce 3 years ago 432MB
|
||||
# loads/redis-sentinel 7.0 6818c626f5ca 3 years ago 104MB
|
||||
# loads/apollo-quick-start latest 8490de672148 3 years ago 190MB
|
||||
# alpine 3.8 c8bccc0af957 5 years ago 4.41MB
|
||||
# loads/oracle-xe-11g-r2 11.2.0 0d19fd2e072e 6 years ago 2.1GB
|
||||
|
||||
# runner@runnervmg1sw1:~/work/gf/gf$ docker ps -s
|
||||
# CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES SIZE
|
||||
# 8214f83420c6 zookeeper:3.8 "/docker-entrypoint.…" 6 minutes ago Up 6 minutes 2888/tcp, 3888/tcp, 0.0.0.0:2181->2181/tcp, [::]:2181->2181/tcp, 8080/tcp d66bac92ae9646f688f70ed4b5176f14_zookeeper38_3a22ef 33kB (virtual 306MB)
|
||||
# 8938d73842e8 loads/dm:v8.1.2.128_ent_x86_64_ctm_pack4 "/bin/bash /opt/star…" 6 minutes ago Up 6 minutes 0.0.0.0:5236->5236/tcp, [::]:5236->5236/tcp ca280fbdb86f40c2acf86d7d526c6285_loadsdmv812128_ent_x86_64_ctm_pack4_770a59 844MB (virtual 1.28GB)
|
||||
# 0d3a653fe1f2 loads/oracle-xe-11g-r2:11.2.0 "/bin/sh -c '/usr/sb…" 6 minutes ago Up 6 minutes 22/tcp, 8080/tcp, 0.0.0.0:1521->1521/tcp, [::]:1521->1521/tcp 2048856d428c4967b1c35193eb8c9192_loadsoraclexe11gr21120_295d54 1.3GB (virtual 3.4GB)
|
||||
# ca3936189166 polarismesh/polaris-standalone:v1.17.2 "/bin/bash run.sh" 6 minutes ago Up 6 minutes 0.0.0.0:8090-8091->8090-8091/tcp, [::]:8090-8091->8090-8091/tcp, 8080/tcp, 8100-8101/tcp, 0.0.0.0:8093->8093/tcp, [::]:8093->8093/tcp, 8761/tcp, 15010/tcp, 0.0.0.0:9090-9091->9090-9091/tcp, [::]:9090-9091->9090-9091/tcp cbd43dceef754e2d8aab507e33167be7_polarismeshpolarisstandalonev1172_ca40b6 299MB (virtual 844MB)
|
||||
# 26169dad485e clickhouse/clickhouse-server:24.11.1.2557-alpine "/entrypoint.sh" 6 minutes ago Up 6 minutes 0.0.0.0:8123->8123/tcp, [::]:8123->8123/tcp, 0.0.0.0:9000-9001->9000-9001/tcp, [::]:9000-9001->9000-9001/tcp, 9009/tcp f1c7766fbe36401792a6f735d7acf123_clickhouseclickhouseserver241112557alpine_cfc034 338kB (virtual 539MB)
|
||||
# 04689a1d581f mcr.microsoft.com/mssql/server:2022-latest "/opt/mssql/bin/laun…" 6 minutes ago Up 6 minutes (healthy) 0.0.0.0:1433->1433/tcp, [::]:1433->1433/tcp 41d685349a7640b28230db8d0f60efe7_mcrmicrosoftcommssqlserver2022latest_fe29fb 108MB (virtual 1.72GB)
|
||||
# d5fbc5f811af postgres:17-alpine "docker-entrypoint.s…" 6 minutes ago Up 6 minutes (healthy) 0.0.0.0:5432->5432/tcp, [::]:5432->5432/tcp 2783be71b5ce417ab9a31428e7b4d8f2_postgres17alpine_c60840 63B (virtual 278MB)
|
||||
# da96a7ad7a01 mariadb:11.4 "docker-entrypoint.s…" 7 minutes ago Up 7 minutes 0.0.0.0:3307->3306/tcp, [::]:3307->3306/tcp 45eed646fa6c4a698893ee11cda95a4c_mariadb114_3a9cd6 2B (virtual 332MB)
|
||||
# 27ba1904ba3a mysql:5.7 "docker-entrypoint.s…" 7 minutes ago Up 7 minutes 0.0.0.0:3306->3306/tcp, [::]:3306->3306/tcp, 33060/tcp ea6d7a4c207d427a95b5ae0db91fdf56_mysql57_c21053 4B (virtual 501MB)
|
||||
# 518e785d1bb6 redis:7.0 "docker-entrypoint.s…" 7 minutes ago Up 7 minutes (healthy) 0.0.0.0:6379->6379/tcp, [::]:6379->6379/tcp af6044fc849e441bbc6c48f7a5ec5fec_redis70_b11994 0B (virtual 109MB)
|
||||
# 7495ec2cd8e3 bitnamilegacy/etcd:3.4.24 "/opt/bitnami/script…" 7 minutes ago Up 7 minutes 0.0.0.0:2379->2379/tcp, [::]:2379->2379/tcp, 2380/tcp 49f2a2a6bf3a4fae842cc950bbc3658a_bitnamilegacyetcd3424_1265e1 145MB (virtual 279MB)
|
||||
|
||||
# runner@runnervmg1sw1:~/work/gf/gf$ du -ah --max-depth=1 /usr | sort -n
|
||||
# 4.0K /usr/games
|
||||
# 4.0K /usr/lib64
|
||||
# 6.6G /usr/lib
|
||||
# 9.3G /usr/share
|
||||
# 15M /usr/lib32
|
||||
# 24G /usr/local
|
||||
# 41G /usr
|
||||
# 95M /usr/sbin
|
||||
# 156M /usr/include
|
||||
# 158M /usr/src
|
||||
# 402M /usr/libexec
|
||||
# 841M /usr/bin
|
||||
|
||||
# runner@runnervmg1sw1:~/work/gf/gf$ du -ah --max-depth=1 /opt | sort -n
|
||||
# 4.0K /opt/pipx_bin
|
||||
# 5.8G /opt/hostedtoolcache
|
||||
# 8.5G /opt
|
||||
# 12K /opt/containerd
|
||||
# 14M /opt/hca
|
||||
# 16K /opt/post-generation
|
||||
# 217M /opt/runner-cache
|
||||
# 243M /opt/actionarchivecache
|
||||
# 374M /opt/google
|
||||
# 515M /opt/pipx
|
||||
# 655M /opt/az
|
||||
# 783M /opt/microsoft
|
||||
|
||||
# runner@runnervmg1sw1:~/work/gf/gf$ du -ah --max-depth=1 /opt/hostedtoolcache/ | sort -n
|
||||
# 1.1G /opt/hostedtoolcache/go
|
||||
# 1.6G /opt/hostedtoolcache/CodeQL
|
||||
# 1.9G /opt/hostedtoolcache/Python
|
||||
# 5.8G /opt/hostedtoolcache/
|
||||
# 9.9M /opt/hostedtoolcache/protoc
|
||||
# 24K /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk
|
||||
# 217M /opt/hostedtoolcache/Ruby
|
||||
# 520M /opt/hostedtoolcache/PyPy
|
||||
# 574M /opt/hostedtoolcache/node
|
||||
|
||||
59
.github/workflows/scripts/ci-main.sh
vendored
Executable file
59
.github/workflows/scripts/ci-main.sh
vendored
Executable file
@ -0,0 +1,59 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
coverage=$1
|
||||
|
||||
# find all path that contains go.mod.
|
||||
for file in `find . -name go.mod`; do
|
||||
dirpath=$(dirname $file)
|
||||
echo $dirpath
|
||||
|
||||
# package kubecm was moved to sub ci procedure.
|
||||
if [ "kubecm" = $(basename $dirpath) ]; then
|
||||
continue 1
|
||||
fi
|
||||
|
||||
# examples directory was moved to sub ci procedure.
|
||||
if [[ $dirpath =~ "/examples/" ]]; then
|
||||
continue 1
|
||||
fi
|
||||
|
||||
if [[ $file =~ "/testdata/" ]]; then
|
||||
echo "ignore testdata path $file"
|
||||
continue 1
|
||||
fi
|
||||
|
||||
# Check if it's a contrib directory
|
||||
if [[ $dirpath =~ "/contrib/" ]]; then
|
||||
# Check if go version meets the requirement
|
||||
if ! go version | grep -qE "go${LATEST_GO_VERSION}"; then
|
||||
echo "ignore path $dirpath as go version is not ${LATEST_GO_VERSION}: $(go version)"
|
||||
# clean docker containers and images to free disk space
|
||||
# bash .github/workflows/scripts/ci-main-clean.sh "$dirpath"
|
||||
continue 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# if [[ $dirpath = "." ]]; then
|
||||
# # No space left on device error sometimes occurs in CI pipelines, so clean the cache before tests.
|
||||
# go clean -cache
|
||||
# fi
|
||||
|
||||
cd $dirpath
|
||||
go mod tidy
|
||||
go build ./...
|
||||
|
||||
# test with coverage
|
||||
if [ "${coverage}" = "coverage" ]; then
|
||||
go test ./... -count=1 -race -coverprofile=coverage.out -covermode=atomic -coverpkg=./...,github.com/gogf/gf/... || exit 1
|
||||
|
||||
if grep -q "/gogf/gf/.*/v2" go.mod; then
|
||||
sed -i "s/gogf\/gf\(\/.*\)\/v2/gogf\/gf\/v2\1/g" coverage.out
|
||||
fi
|
||||
else
|
||||
go test ./... -count=1 -race || exit 1
|
||||
fi
|
||||
|
||||
cd -
|
||||
# clean docker containers and images to free disk space
|
||||
# bash .github/workflows/scripts/ci-main-clean.sh "$dirpath"
|
||||
done
|
||||
86
.github/workflows/scripts/ci-sub.sh
vendored
Executable file
86
.github/workflows/scripts/ci-sub.sh
vendored
Executable file
@ -0,0 +1,86 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
coverage=$1
|
||||
|
||||
# update code of submodules
|
||||
git clone https://github.com/gogf/examples
|
||||
|
||||
# update go.mod in examples directory to replace github.com/gogf/gf packages with local directory
|
||||
bash .github/workflows/scripts/replace_examples_gomod.sh
|
||||
|
||||
# Function to compare version numbers
|
||||
version_compare() {
|
||||
local ver1=$1
|
||||
local ver2=$2
|
||||
|
||||
# Remove 'go' prefix and 'v' if present
|
||||
ver1=$(echo "$ver1" | sed 's/^go//; s/^v//')
|
||||
ver2=$(echo "$ver2" | sed 's/^go//; s/^v//')
|
||||
|
||||
# Split versions into major.minor format
|
||||
local major1=$(echo "$ver1" | cut -d. -f1)
|
||||
local minor1=$(echo "$ver1" | cut -d. -f2)
|
||||
local major2=$(echo "$ver2" | cut -d. -f1)
|
||||
local minor2=$(echo "$ver2" | cut -d. -f2)
|
||||
|
||||
# Compare versions: return 0 if ver1 <= ver2, 1 otherwise
|
||||
if [ "$major1" -lt "$major2" ]; then
|
||||
return 0
|
||||
elif [ "$major1" -eq "$major2" ] && [ "$minor1" -le "$minor2" ]; then
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
# Get current Go version
|
||||
current_go_version=$(go version | grep -oE 'go[0-9]+\.[0-9]+')
|
||||
|
||||
# find all path that contains go.mod.
|
||||
for file in `find . -name go.mod`; do
|
||||
dirpath=$(dirname $file)
|
||||
echo "Processing: $dirpath"
|
||||
|
||||
# Only process examples and kubecm directories
|
||||
|
||||
# Process examples directory (only build, no tests)
|
||||
if [[ $dirpath =~ "/examples/" ]]; then
|
||||
echo " the examples directory only needs to be built, not unit tests."
|
||||
cd $dirpath
|
||||
go mod tidy
|
||||
go build ./...
|
||||
cd -
|
||||
continue 1
|
||||
fi
|
||||
|
||||
# Process kubecm directory
|
||||
if [ "kubecm" != $(basename $dirpath) ]; then
|
||||
echo " Skipping: not kubecm directory"
|
||||
continue
|
||||
fi
|
||||
|
||||
cd $dirpath
|
||||
|
||||
# Read Go version requirement from go.mod
|
||||
if [ -f "go.mod" ]; then
|
||||
go_mod_version=$(grep '^go ' go.mod | awk '{print $2}' | head -1)
|
||||
|
||||
if [ -n "$go_mod_version" ]; then
|
||||
echo " go.mod requires: go$go_mod_version"
|
||||
echo " current version: $current_go_version"
|
||||
|
||||
# Check if go.mod version requirement is satisfied by current Go version
|
||||
if version_compare "$go_mod_version" "$current_go_version"; then
|
||||
echo " ✓ Version requirement satisfied, proceeding with build and test"
|
||||
|
||||
go mod tidy
|
||||
go build ./...
|
||||
go test ./... -race || exit 1
|
||||
else
|
||||
echo " ✗ Current Go version ($current_go_version) does not meet requirement (go$go_mod_version), skipping"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
cd -
|
||||
done
|
||||
785
.github/workflows/scripts/docker-services.sh
vendored
Executable file
785
.github/workflows/scripts/docker-services.sh
vendored
Executable file
@ -0,0 +1,785 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# GoFrame Docker Services Manager
|
||||
# For managing Docker services used in local development and testing
|
||||
#
|
||||
|
||||
set -e
|
||||
|
||||
# Container name prefix
|
||||
PREFIX="goframe"
|
||||
|
||||
# Color definitions
|
||||
RED='\033[0;31m'
|
||||
GREEN='\033[0;32m'
|
||||
YELLOW='\033[1;33m'
|
||||
BLUE='\033[0;34m'
|
||||
CYAN='\033[0;36m'
|
||||
NC='\033[0m' # No Color
|
||||
|
||||
# Service definitions
|
||||
declare -A SERVICES
|
||||
declare -A SERVICE_PORTS
|
||||
declare -A SERVICE_ENVS
|
||||
declare -A SERVICE_OPTS
|
||||
|
||||
# Basic services
|
||||
SERVICES["etcd"]="bitnamilegacy/etcd:3.4.24"
|
||||
SERVICE_PORTS["etcd"]="2379:2379"
|
||||
SERVICE_ENVS["etcd"]="-e ALLOW_NONE_AUTHENTICATION=yes"
|
||||
|
||||
SERVICES["redis"]="redis:7.0"
|
||||
SERVICE_PORTS["redis"]="6379:6379"
|
||||
SERVICE_OPTS["redis"]="--health-cmd 'redis-cli ping' --health-interval 10s --health-timeout 5s --health-retries 5"
|
||||
|
||||
SERVICES["mysql"]="mysql:5.7"
|
||||
SERVICE_PORTS["mysql"]="3306:3306"
|
||||
SERVICE_ENVS["mysql"]="-e MYSQL_DATABASE=test -e MYSQL_ROOT_PASSWORD=12345678"
|
||||
|
||||
SERVICES["mariadb"]="mariadb:11.4"
|
||||
SERVICE_PORTS["mariadb"]="3307:3306"
|
||||
SERVICE_ENVS["mariadb"]="-e MARIADB_DATABASE=test -e MARIADB_ROOT_PASSWORD=12345678"
|
||||
|
||||
SERVICES["postgres"]="postgres:17-alpine"
|
||||
SERVICE_PORTS["postgres"]="5432:5432"
|
||||
SERVICE_ENVS["postgres"]="-e POSTGRES_PASSWORD=12345678 -e POSTGRES_USER=postgres -e POSTGRES_DB=test -e TZ=Asia/Shanghai"
|
||||
SERVICE_OPTS["postgres"]="--health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5"
|
||||
|
||||
SERVICES["mssql"]="mcr.microsoft.com/mssql/server:2022-latest"
|
||||
SERVICE_PORTS["mssql"]="1433:1433"
|
||||
SERVICE_ENVS["mssql"]="-e TZ=Asia/Shanghai -e ACCEPT_EULA=Y -e MSSQL_SA_PASSWORD=LoremIpsum86"
|
||||
|
||||
SERVICES["clickhouse"]="clickhouse/clickhouse-server:24.11.1.2557-alpine"
|
||||
SERVICE_PORTS["clickhouse"]="9000:9000 -p 8123:8123 -p 9001:9001"
|
||||
|
||||
SERVICES["polaris"]="polarismesh/polaris-standalone:v1.17.2"
|
||||
SERVICE_PORTS["polaris"]="8090:8090 -p 8091:8091 -p 8093:8093 -p 9090:9090 -p 9091:9091"
|
||||
|
||||
SERVICES["oracle"]="loads/oracle-xe-11g-r2:11.2.0"
|
||||
SERVICE_PORTS["oracle"]="1521:1521"
|
||||
SERVICE_ENVS["oracle"]="-e ORACLE_ALLOW_REMOTE=true -e ORACLE_SID=XE -e ORACLE_DB_USER_NAME=system -e ORACLE_DB_PASSWORD=oracle"
|
||||
|
||||
SERVICES["dm"]="loads/dm:v8.1.2.128_ent_x86_64_ctm_pack4"
|
||||
SERVICE_PORTS["dm"]="5236:5236"
|
||||
|
||||
SERVICES["gaussdb"]="opengauss/opengauss:7.0.0-RC1.B023"
|
||||
SERVICE_PORTS["gaussdb"]="9950:5432"
|
||||
SERVICE_ENVS["gaussdb"]="-e GS_PASSWORD=UTpass@1234 -e TZ=Asia/Shanghai"
|
||||
SERVICE_OPTS["gaussdb"]="--privileged=true"
|
||||
|
||||
SERVICES["zookeeper"]="zookeeper:3.8"
|
||||
SERVICE_PORTS["zookeeper"]="2181:2181"
|
||||
|
||||
# Service groups
|
||||
GROUP_DB="mysql mariadb postgres mssql oracle dm gaussdb clickhouse"
|
||||
GROUP_CACHE="redis etcd"
|
||||
GROUP_REGISTRY="polaris zookeeper"
|
||||
GROUP_ALL="etcd redis mysql mariadb postgres mssql clickhouse polaris oracle dm gaussdb zookeeper"
|
||||
|
||||
# Working directories
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
PROJECT_ROOT="$(dirname "$SCRIPT_DIR")"
|
||||
WORKFLOW_DIR="$PROJECT_ROOT/.github/workflows"
|
||||
|
||||
# Print colored messages
|
||||
print_info() {
|
||||
echo -e "${BLUE}[INFO]${NC} $1"
|
||||
}
|
||||
|
||||
print_success() {
|
||||
echo -e "${GREEN}[OK]${NC} $1"
|
||||
}
|
||||
|
||||
print_warning() {
|
||||
echo -e "${YELLOW}[WARN]${NC} $1"
|
||||
}
|
||||
|
||||
print_error() {
|
||||
echo -e "${RED}[ERROR]${NC} $1"
|
||||
}
|
||||
|
||||
# Check if Docker is available
|
||||
check_docker() {
|
||||
if ! command -v docker &> /dev/null; then
|
||||
print_error "Docker is not installed or not in PATH"
|
||||
exit 1
|
||||
fi
|
||||
if ! docker info &> /dev/null; then
|
||||
print_error "Docker service is not running"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
# Get container name
|
||||
get_container_name() {
|
||||
echo "${PREFIX}-$1"
|
||||
}
|
||||
|
||||
# Start a single service
|
||||
start_service() {
|
||||
local service=$1
|
||||
local container_name=$(get_container_name "$service")
|
||||
local image="${SERVICES[$service]}"
|
||||
local ports="${SERVICE_PORTS[$service]}"
|
||||
local envs="${SERVICE_ENVS[$service]}"
|
||||
local opts="${SERVICE_OPTS[$service]}"
|
||||
|
||||
if [ -z "$image" ]; then
|
||||
print_error "Unknown service: $service"
|
||||
return 1
|
||||
fi
|
||||
|
||||
# Check if container already exists
|
||||
if docker ps -a --format '{{.Names}}' | grep -q "^${container_name}$"; then
|
||||
if docker ps --format '{{.Names}}' | grep -q "^${container_name}$"; then
|
||||
print_warning "$service is already running"
|
||||
return 0
|
||||
else
|
||||
print_info "Starting existing container $service..."
|
||||
docker start "$container_name" > /dev/null
|
||||
print_success "$service started"
|
||||
return 0
|
||||
fi
|
||||
fi
|
||||
|
||||
print_info "Starting $service..."
|
||||
|
||||
# Build docker run command
|
||||
local cmd="docker run -d --name $container_name"
|
||||
|
||||
# Add port mappings
|
||||
for port in $ports; do
|
||||
cmd="$cmd -p $port"
|
||||
done
|
||||
|
||||
# Add environment variables
|
||||
if [ -n "$envs" ]; then
|
||||
cmd="$cmd $envs"
|
||||
fi
|
||||
|
||||
# Add other options
|
||||
if [ -n "$opts" ]; then
|
||||
cmd="$cmd $opts"
|
||||
fi
|
||||
|
||||
cmd="$cmd $image"
|
||||
|
||||
if eval "$cmd" > /dev/null 2>&1; then
|
||||
print_success "$service started (container: $container_name)"
|
||||
else
|
||||
print_error "Failed to start $service"
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
# Stop a single service
|
||||
stop_service() {
|
||||
local service=$1
|
||||
local container_name=$(get_container_name "$service")
|
||||
|
||||
if docker ps --format '{{.Names}}' | grep -q "^${container_name}$"; then
|
||||
print_info "Stopping $service..."
|
||||
docker stop "$container_name" > /dev/null
|
||||
print_success "$service stopped"
|
||||
else
|
||||
print_warning "$service is not running"
|
||||
fi
|
||||
}
|
||||
|
||||
# Remove a single service
|
||||
remove_service() {
|
||||
local service=$1
|
||||
local container_name=$(get_container_name "$service")
|
||||
|
||||
if docker ps -a --format '{{.Names}}' | grep -q "^${container_name}$"; then
|
||||
print_info "Removing $service..."
|
||||
docker rm -f "$container_name" > /dev/null
|
||||
print_success "$service removed"
|
||||
else
|
||||
print_warning "$service container does not exist"
|
||||
fi
|
||||
}
|
||||
|
||||
# View service logs
|
||||
logs_service() {
|
||||
local service=$1
|
||||
local container_name=$(get_container_name "$service")
|
||||
local lines=${2:-100}
|
||||
|
||||
if docker ps -a --format '{{.Names}}' | grep -q "^${container_name}$"; then
|
||||
docker logs --tail "$lines" -f "$container_name"
|
||||
else
|
||||
print_error "$service container does not exist"
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
# Start docker-compose service
|
||||
start_compose_service() {
|
||||
local service=$1
|
||||
local compose_file=""
|
||||
|
||||
case $service in
|
||||
apollo)
|
||||
compose_file="$WORKFLOW_DIR/apollo/docker-compose.yml"
|
||||
;;
|
||||
nacos)
|
||||
compose_file="$WORKFLOW_DIR/nacos/docker-compose.yml"
|
||||
;;
|
||||
redis-cluster)
|
||||
compose_file="$WORKFLOW_DIR/redis/docker-compose.yml"
|
||||
;;
|
||||
consul)
|
||||
compose_file="$WORKFLOW_DIR/consul/docker-compose.yml"
|
||||
;;
|
||||
*)
|
||||
print_error "Unknown compose service: $service"
|
||||
return 1
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -f "$compose_file" ]; then
|
||||
print_info "Starting $service (docker-compose)..."
|
||||
docker compose -f "$compose_file" up -d
|
||||
print_success "$service started"
|
||||
else
|
||||
print_error "Compose file does not exist: $compose_file"
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
# Stop docker-compose service
|
||||
stop_compose_service() {
|
||||
local service=$1
|
||||
local compose_file=""
|
||||
|
||||
case $service in
|
||||
apollo)
|
||||
compose_file="$WORKFLOW_DIR/apollo/docker-compose.yml"
|
||||
;;
|
||||
nacos)
|
||||
compose_file="$WORKFLOW_DIR/nacos/docker-compose.yml"
|
||||
;;
|
||||
redis-cluster)
|
||||
compose_file="$WORKFLOW_DIR/redis/docker-compose.yml"
|
||||
;;
|
||||
consul)
|
||||
compose_file="$WORKFLOW_DIR/consul/docker-compose.yml"
|
||||
;;
|
||||
*)
|
||||
print_error "Unknown compose service: $service"
|
||||
return 1
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -f "$compose_file" ]; then
|
||||
print_info "Stopping $service (docker-compose)..."
|
||||
docker compose -f "$compose_file" down
|
||||
print_success "$service stopped"
|
||||
else
|
||||
print_error "Compose file does not exist: $compose_file"
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
# Show service status
|
||||
show_status() {
|
||||
echo ""
|
||||
echo -e "${CYAN}========== GoFrame Docker Services Status ==========${NC}"
|
||||
echo ""
|
||||
printf "%-15s %-12s %-30s %s\n" "SERVICE" "STATUS" "CONTAINER" "PORTS"
|
||||
echo "--------------------------------------------------------------------------------"
|
||||
|
||||
for service in $GROUP_ALL; do
|
||||
local container_name=$(get_container_name "$service")
|
||||
local status="stopped"
|
||||
local ports="-"
|
||||
|
||||
if docker ps --format '{{.Names}}' 2>/dev/null | grep -q "^${container_name}$"; then
|
||||
status="${GREEN}running${NC}"
|
||||
ports=$(docker port "$container_name" 2>/dev/null | tr '\n' ' ' || echo "-")
|
||||
elif docker ps -a --format '{{.Names}}' 2>/dev/null | grep -q "^${container_name}$"; then
|
||||
status="${YELLOW}stopped${NC}"
|
||||
else
|
||||
status="${RED}not created${NC}"
|
||||
fi
|
||||
|
||||
printf "%-15s %-22b %-30s %s\n" "$service" "$status" "$container_name" "$ports"
|
||||
done
|
||||
|
||||
echo ""
|
||||
echo -e "${CYAN}========== Compose Services ==========${NC}"
|
||||
echo ""
|
||||
|
||||
for compose_svc in apollo nacos redis-cluster consul; do
|
||||
local running=0
|
||||
case $compose_svc in
|
||||
apollo)
|
||||
running=$(docker ps --filter "name=apollo" --format '{{.Names}}' 2>/dev/null | wc -l)
|
||||
;;
|
||||
nacos)
|
||||
running=$(docker ps --filter "name=nacos" --format '{{.Names}}' 2>/dev/null | wc -l)
|
||||
;;
|
||||
redis-cluster)
|
||||
running=$(docker ps --filter "name=redis-" --format '{{.Names}}' 2>/dev/null | wc -l)
|
||||
;;
|
||||
consul)
|
||||
running=$(docker ps --filter "name=consul" --format '{{.Names}}' 2>/dev/null | wc -l)
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ "$running" -gt 0 ]; then
|
||||
printf "%-15s ${GREEN}running${NC} (%d containers)\n" "$compose_svc" "$running"
|
||||
else
|
||||
printf "%-15s ${RED}stopped${NC}\n" "$compose_svc"
|
||||
fi
|
||||
done
|
||||
|
||||
echo ""
|
||||
}
|
||||
|
||||
# Show service information
|
||||
show_service_info() {
|
||||
echo ""
|
||||
echo -e "${CYAN}========== Available Services ==========${NC}"
|
||||
echo ""
|
||||
echo -e "${YELLOW}Basic Services (standalone containers):${NC}"
|
||||
echo ""
|
||||
printf "%-15s %-50s %s\n" "SERVICE" "IMAGE" "PORTS"
|
||||
echo "--------------------------------------------------------------------------------"
|
||||
|
||||
for service in $GROUP_ALL; do
|
||||
printf "%-15s %-50s %s\n" "$service" "${SERVICES[$service]}" "${SERVICE_PORTS[$service]}"
|
||||
done
|
||||
|
||||
echo ""
|
||||
echo -e "${YELLOW}Compose Services (multi-container):${NC}"
|
||||
echo " apollo - Apollo Config Center (8080, 8070, 8060, 13306)"
|
||||
echo " nacos - Nacos Registry (8848, 9848, 9555)"
|
||||
echo " redis-cluster - Redis Primary-Replica + Sentinel Cluster (6380-6382, 26379-26381)"
|
||||
echo " consul - Consul Service Discovery (8500, 8600)"
|
||||
echo ""
|
||||
echo -e "${YELLOW}Service Groups:${NC}"
|
||||
echo " db - Databases: $GROUP_DB"
|
||||
echo " cache - Cache: $GROUP_CACHE"
|
||||
echo " registry - Registry: $GROUP_REGISTRY"
|
||||
echo " all - All basic services"
|
||||
echo ""
|
||||
}
|
||||
|
||||
# Show help
|
||||
show_help() {
|
||||
echo ""
|
||||
echo -e "${CYAN}GoFrame Docker Services Manager${NC}"
|
||||
echo ""
|
||||
echo "Usage: $0 <command> [service|group] [options]"
|
||||
echo ""
|
||||
echo "Commands:"
|
||||
echo " start <service|group> Start service or service group"
|
||||
echo " stop <service|group> Stop service or service group"
|
||||
echo " restart <service|group> Restart service or service group"
|
||||
echo " remove <service|group> Remove service container"
|
||||
echo " logs <service> [lines] View service logs (default 100 lines)"
|
||||
echo " status Show all service status"
|
||||
echo " info Show available service information"
|
||||
echo " clean Remove all goframe containers"
|
||||
echo " pull [service] Pull images"
|
||||
echo ""
|
||||
echo "Services:"
|
||||
echo " Basic: etcd, redis, mysql, mariadb, postgres, mssql,"
|
||||
echo " clickhouse, polaris, oracle, dm, gaussdb, zookeeper"
|
||||
echo " Compose: apollo, nacos, redis-cluster, consul"
|
||||
echo ""
|
||||
echo "Service Groups:"
|
||||
echo " db - All database services"
|
||||
echo " cache - Cache services (redis, etcd)"
|
||||
echo " registry - Registry services (polaris, zookeeper)"
|
||||
echo " all - All basic services"
|
||||
echo ""
|
||||
echo "Examples:"
|
||||
echo " $0 start mysql # Start MySQL"
|
||||
echo " $0 start db # Start all databases"
|
||||
echo " $0 start all # Start all basic services"
|
||||
echo " $0 start apollo # Start Apollo (compose)"
|
||||
echo " $0 stop all # Stop all basic services"
|
||||
echo " $0 logs mysql 50 # View last 50 lines of MySQL logs"
|
||||
echo " $0 status # View service status"
|
||||
echo ""
|
||||
}
|
||||
|
||||
# Parse service groups
|
||||
parse_services() {
|
||||
local input=$1
|
||||
case $input in
|
||||
db)
|
||||
echo "$GROUP_DB"
|
||||
;;
|
||||
cache)
|
||||
echo "$GROUP_CACHE"
|
||||
;;
|
||||
registry)
|
||||
echo "$GROUP_REGISTRY"
|
||||
;;
|
||||
all)
|
||||
echo "$GROUP_ALL"
|
||||
;;
|
||||
*)
|
||||
echo "$input"
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
# Check if it's a compose service
|
||||
is_compose_service() {
|
||||
local service=$1
|
||||
case $service in
|
||||
apollo|nacos|redis-cluster|consul)
|
||||
return 0
|
||||
;;
|
||||
*)
|
||||
return 1
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
# Pull images
|
||||
pull_images() {
|
||||
local services=$1
|
||||
|
||||
if [ -z "$services" ]; then
|
||||
services="$GROUP_ALL"
|
||||
fi
|
||||
|
||||
for service in $services; do
|
||||
if [ -n "${SERVICES[$service]}" ]; then
|
||||
print_info "Pulling image: ${SERVICES[$service]}"
|
||||
docker pull "${SERVICES[$service]}"
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
# Clean all goframe containers
|
||||
clean_all() {
|
||||
print_info "Removing all $PREFIX containers..."
|
||||
local containers=$(docker ps -a --filter "name=$PREFIX" --format '{{.Names}}')
|
||||
|
||||
if [ -n "$containers" ]; then
|
||||
for container in $containers; do
|
||||
docker rm -f "$container" > /dev/null
|
||||
print_success "Removed: $container"
|
||||
done
|
||||
else
|
||||
print_info "No $PREFIX containers found"
|
||||
fi
|
||||
}
|
||||
|
||||
# Get service status mark
|
||||
get_service_status_mark() {
|
||||
local service=$1
|
||||
local container_name=$(get_container_name "$service")
|
||||
|
||||
if docker ps --format '{{.Names}}' 2>/dev/null | grep -q "^${container_name}$"; then
|
||||
echo -e "${GREEN}*${NC}"
|
||||
else
|
||||
echo " "
|
||||
fi
|
||||
}
|
||||
|
||||
# Get compose service status mark
|
||||
get_compose_status_mark() {
|
||||
local service=$1
|
||||
local running=0
|
||||
|
||||
case $service in
|
||||
apollo)
|
||||
running=$(docker ps --filter "name=apollo" --format '{{.Names}}' 2>/dev/null | wc -l)
|
||||
;;
|
||||
nacos)
|
||||
running=$(docker ps --filter "name=nacos" --format '{{.Names}}' 2>/dev/null | wc -l)
|
||||
;;
|
||||
redis-cluster)
|
||||
running=$(docker ps --filter "name=redis-" --format '{{.Names}}' 2>/dev/null | wc -l)
|
||||
;;
|
||||
consul)
|
||||
running=$(docker ps --filter "name=consul" --format '{{.Names}}' 2>/dev/null | wc -l)
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ "$running" -gt 0 ]; then
|
||||
echo -e "${GREEN}*${NC}"
|
||||
else
|
||||
echo " "
|
||||
fi
|
||||
}
|
||||
|
||||
# Service selection menu
|
||||
select_service_menu() {
|
||||
local action=$1
|
||||
local action_name=$2
|
||||
|
||||
echo ""
|
||||
echo -e "${CYAN}========== Select Service to ${action_name} ==========${NC}"
|
||||
|
||||
# Show running status for stop/restart/logs operations
|
||||
if [[ "$action" == "stop" || "$action" == "restart" || "$action" == "logs" ]]; then
|
||||
echo -e " (${GREEN}*${NC} indicates running)"
|
||||
fi
|
||||
echo ""
|
||||
echo -e "${YELLOW}Basic Services:${NC}"
|
||||
printf " %b1) etcd %b2) redis %b3) mysql\n" \
|
||||
"$(get_service_status_mark etcd)" "$(get_service_status_mark redis)" "$(get_service_status_mark mysql)"
|
||||
printf " %b4) mariadb %b5) postgres %b6) mssql\n" \
|
||||
"$(get_service_status_mark mariadb)" "$(get_service_status_mark postgres)" "$(get_service_status_mark mssql)"
|
||||
printf " %b7) clickhouse %b8) polaris %b9) oracle\n" \
|
||||
"$(get_service_status_mark clickhouse)" "$(get_service_status_mark polaris)" "$(get_service_status_mark oracle)"
|
||||
printf " %b10) dm %b11) gaussdb %b12) zookeeper\n" \
|
||||
"$(get_service_status_mark dm)" "$(get_service_status_mark gaussdb)" "$(get_service_status_mark zookeeper)"
|
||||
echo ""
|
||||
echo -e "${YELLOW}Compose Services:${NC}"
|
||||
printf " %b13) apollo %b14) nacos %b15) redis-cluster\n" \
|
||||
"$(get_compose_status_mark apollo)" "$(get_compose_status_mark nacos)" "$(get_compose_status_mark redis-cluster)"
|
||||
printf " %b16) consul\n" "$(get_compose_status_mark consul)"
|
||||
echo ""
|
||||
echo -e "${YELLOW}Service Groups:${NC}"
|
||||
echo " 17) db (all databases) 18) cache (cache services)"
|
||||
echo " 19) registry (registry services) 20) all (all basic services)"
|
||||
echo ""
|
||||
echo " 0) Back to main menu"
|
||||
echo ""
|
||||
read -p "Select [0-20]: " svc_choice
|
||||
|
||||
local svc=""
|
||||
case $svc_choice in
|
||||
1) svc="etcd" ;;
|
||||
2) svc="redis" ;;
|
||||
3) svc="mysql" ;;
|
||||
4) svc="mariadb" ;;
|
||||
5) svc="postgres" ;;
|
||||
6) svc="mssql" ;;
|
||||
7) svc="clickhouse" ;;
|
||||
8) svc="polaris" ;;
|
||||
9) svc="oracle" ;;
|
||||
10) svc="dm" ;;
|
||||
11) svc="gaussdb" ;;
|
||||
12) svc="zookeeper" ;;
|
||||
13) svc="apollo" ;;
|
||||
14) svc="nacos" ;;
|
||||
15) svc="redis-cluster" ;;
|
||||
16) svc="consul" ;;
|
||||
17) svc="db" ;;
|
||||
18) svc="cache" ;;
|
||||
19) svc="registry" ;;
|
||||
20) svc="all" ;;
|
||||
0) return ;;
|
||||
*)
|
||||
print_error "Invalid selection"
|
||||
return
|
||||
;;
|
||||
esac
|
||||
|
||||
case $action in
|
||||
start)
|
||||
if is_compose_service "$svc"; then
|
||||
start_compose_service "$svc"
|
||||
else
|
||||
for s in $(parse_services "$svc"); do
|
||||
start_service "$s"
|
||||
done
|
||||
fi
|
||||
;;
|
||||
stop)
|
||||
if is_compose_service "$svc"; then
|
||||
stop_compose_service "$svc"
|
||||
else
|
||||
for s in $(parse_services "$svc"); do
|
||||
stop_service "$s"
|
||||
done
|
||||
fi
|
||||
;;
|
||||
restart)
|
||||
if is_compose_service "$svc"; then
|
||||
stop_compose_service "$svc"
|
||||
start_compose_service "$svc"
|
||||
else
|
||||
for s in $(parse_services "$svc"); do
|
||||
stop_service "$s"
|
||||
start_service "$s"
|
||||
done
|
||||
fi
|
||||
;;
|
||||
remove)
|
||||
for s in $(parse_services "$svc"); do
|
||||
remove_service "$s"
|
||||
done
|
||||
;;
|
||||
logs)
|
||||
if is_compose_service "$svc"; then
|
||||
print_error "For Compose services, please use 'docker compose logs'"
|
||||
else
|
||||
read -p "Number of lines (default 100): " lines
|
||||
lines=${lines:-100}
|
||||
logs_service "$svc" "$lines"
|
||||
fi
|
||||
;;
|
||||
pull)
|
||||
pull_images "$(parse_services "$svc")"
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
# Interactive menu
|
||||
interactive_menu() {
|
||||
while true; do
|
||||
echo ""
|
||||
echo -e "${CYAN}========== GoFrame Docker Services Manager ==========${NC}"
|
||||
echo ""
|
||||
echo " 1) Start Service"
|
||||
echo " 2) Stop Service"
|
||||
echo " 3) Restart Service"
|
||||
echo " 4) Remove Service"
|
||||
echo " 5) View Logs"
|
||||
echo " 6) View Status"
|
||||
echo " 7) Service Info"
|
||||
echo " 8) Clean All Containers"
|
||||
echo " 9) Pull Images"
|
||||
echo " 0) Exit"
|
||||
echo ""
|
||||
read -p "Select operation [0-9]: " choice
|
||||
|
||||
case $choice in
|
||||
1)
|
||||
select_service_menu "start" "Start"
|
||||
;;
|
||||
2)
|
||||
select_service_menu "stop" "Stop"
|
||||
;;
|
||||
3)
|
||||
select_service_menu "restart" "Restart"
|
||||
;;
|
||||
4)
|
||||
select_service_menu "remove" "Remove"
|
||||
;;
|
||||
5)
|
||||
select_service_menu "logs" "View Logs"
|
||||
;;
|
||||
6)
|
||||
show_status
|
||||
;;
|
||||
7)
|
||||
show_service_info
|
||||
;;
|
||||
8)
|
||||
read -p "Confirm removing all goframe containers? [y/N]: " confirm
|
||||
if [[ "$confirm" =~ ^[Yy]$ ]]; then
|
||||
clean_all
|
||||
fi
|
||||
;;
|
||||
9)
|
||||
select_service_menu "pull" "Pull Images"
|
||||
;;
|
||||
0)
|
||||
echo "Goodbye!"
|
||||
exit 0
|
||||
;;
|
||||
*)
|
||||
print_error "Invalid selection"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
}
|
||||
|
||||
# Main function
|
||||
main() {
|
||||
check_docker
|
||||
|
||||
if [ $# -eq 0 ]; then
|
||||
interactive_menu
|
||||
exit 0
|
||||
fi
|
||||
|
||||
local command=$1
|
||||
local target=$2
|
||||
local extra=$3
|
||||
|
||||
case $command in
|
||||
start)
|
||||
if [ -z "$target" ]; then
|
||||
print_error "Please specify service name or service group"
|
||||
exit 1
|
||||
fi
|
||||
if is_compose_service "$target"; then
|
||||
start_compose_service "$target"
|
||||
else
|
||||
for service in $(parse_services "$target"); do
|
||||
start_service "$service"
|
||||
done
|
||||
fi
|
||||
;;
|
||||
stop)
|
||||
if [ -z "$target" ]; then
|
||||
print_error "Please specify service name or service group"
|
||||
exit 1
|
||||
fi
|
||||
if is_compose_service "$target"; then
|
||||
stop_compose_service "$target"
|
||||
else
|
||||
for service in $(parse_services "$target"); do
|
||||
stop_service "$service"
|
||||
done
|
||||
fi
|
||||
;;
|
||||
restart)
|
||||
if [ -z "$target" ]; then
|
||||
print_error "Please specify service name or service group"
|
||||
exit 1
|
||||
fi
|
||||
if is_compose_service "$target"; then
|
||||
stop_compose_service "$target"
|
||||
start_compose_service "$target"
|
||||
else
|
||||
for service in $(parse_services "$target"); do
|
||||
stop_service "$service"
|
||||
start_service "$service"
|
||||
done
|
||||
fi
|
||||
;;
|
||||
remove|rm)
|
||||
if [ -z "$target" ]; then
|
||||
print_error "Please specify service name or service group"
|
||||
exit 1
|
||||
fi
|
||||
for service in $(parse_services "$target"); do
|
||||
remove_service "$service"
|
||||
done
|
||||
;;
|
||||
logs)
|
||||
if [ -z "$target" ]; then
|
||||
print_error "Please specify service name"
|
||||
exit 1
|
||||
fi
|
||||
logs_service "$target" "${extra:-100}"
|
||||
;;
|
||||
status|ps)
|
||||
show_status
|
||||
;;
|
||||
info|list)
|
||||
show_service_info
|
||||
;;
|
||||
clean)
|
||||
clean_all
|
||||
;;
|
||||
pull)
|
||||
pull_images "$target"
|
||||
;;
|
||||
help|--help|-h)
|
||||
show_help
|
||||
;;
|
||||
*)
|
||||
print_error "Unknown command: $command"
|
||||
show_help
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
main "$@"
|
||||
81
.github/workflows/scripts/replace_examples_gomod.sh
vendored
Executable file
81
.github/workflows/scripts/replace_examples_gomod.sh
vendored
Executable file
@ -0,0 +1,81 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Get the absolute path to the repository root
|
||||
repo_root=$(pwd)
|
||||
workdir=$repo_root/examples
|
||||
|
||||
echo "Prepare to process go.mod files in the ${workdir} directory"
|
||||
|
||||
# Check if examples directory exists
|
||||
if [ ! -d "${workdir}" ]; then
|
||||
echo "Error: examples directory not found at ${workdir}"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Check if find command is available
|
||||
if ! command -v find &> /dev/null; then
|
||||
echo "Error: find command not found!"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
for file in `find ${workdir} -name go.mod`; do
|
||||
goModPath=$(dirname $file)
|
||||
echo ""
|
||||
echo "Processing dir: $goModPath"
|
||||
|
||||
# Calculate relative path to root
|
||||
# First get the relative path from go.mod to repo root
|
||||
relativePath=""
|
||||
current="$goModPath"
|
||||
while [ "$current" != "$repo_root" ]; do
|
||||
relativePath="../$relativePath"
|
||||
current=$(dirname "$current")
|
||||
done
|
||||
relativePath=${relativePath%/} # Remove trailing slash
|
||||
echo "Relative path to root: $relativePath"
|
||||
|
||||
# Get all github.com/gogf/gf dependencies
|
||||
# Use awk to get package names without version numbers
|
||||
dependencies=$(awk '/^[[:space:]]*github\.com\/gogf\/gf\// {print $1}' "$file" | sort -u)
|
||||
|
||||
if [ -n "$dependencies" ]; then
|
||||
echo "Found GoFrame dependencies:"
|
||||
echo "$dependencies"
|
||||
echo "Adding replace directives..."
|
||||
|
||||
# Create temporary file
|
||||
temp_file="${file}.tmp"
|
||||
# Remove existing replace directives and copy to temp file
|
||||
sed '/^replace.*github\.com\/gogf\/gf.*/d' "$file" > "$temp_file"
|
||||
|
||||
# Add new replace block
|
||||
echo "" >> "$temp_file"
|
||||
echo "replace (" >> "$temp_file"
|
||||
|
||||
while IFS= read -r dep; do
|
||||
# Skip empty lines
|
||||
[ -z "$dep" ] && continue
|
||||
|
||||
# Calculate the relative path for the replacement
|
||||
if [[ "$dep" == "github.com/gogf/gf/v2" ]]; then
|
||||
replacement="$relativePath"
|
||||
else
|
||||
# Extract the path after v2 and remove trailing version
|
||||
subpath=$(echo "$dep" | sed -E 's/github\.com\/gogf\/gf\/(contrib\/[^/]+\/[^/]+)\/v2.*/\1/')
|
||||
replacement="$relativePath/$subpath"
|
||||
fi
|
||||
|
||||
echo " $dep => $replacement/" >> "$temp_file"
|
||||
done <<< "$dependencies"
|
||||
|
||||
echo ")" >> "$temp_file"
|
||||
|
||||
# Replace original file with temporary file
|
||||
mv "$temp_file" "$file"
|
||||
echo "Replace directives added to $file"
|
||||
else
|
||||
echo "No GoFrame dependencies found in $file"
|
||||
fi
|
||||
done
|
||||
|
||||
echo "\nAll go.mod files have been processed successfully."
|
||||
50
.github/workflows/scripts/update_version.sh
vendored
Executable file
50
.github/workflows/scripts/update_version.sh
vendored
Executable file
@ -0,0 +1,50 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Check if the number of parameters is 2
|
||||
if [ $# -ne 2 ]; then
|
||||
echo "Invalid parameters, please execute in format: version.sh [directory] [version]"
|
||||
echo "Example: version.sh ./contrib v1.0.0"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Check if the first parameter is a directory and exists
|
||||
if [ ! -d "$1" ]; then
|
||||
echo "Error: Directory does not exist"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Check if the second parameter starts with 'v'
|
||||
if [[ "$2" != v* ]]; then
|
||||
echo "Error: Version number does not start with 'v'"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
workdir=$1
|
||||
newVersion=$2
|
||||
echo "Preparing to replace version numbers in all go.mod files under ${workdir} directory to ${newVersion}"
|
||||
|
||||
|
||||
# Check if file exists
|
||||
if [ -f "go.work" ]; then
|
||||
# File exists, rename it
|
||||
mv go.work go.work.${newVersion}
|
||||
echo "Backup go.work file to avoid affecting the upgrade"
|
||||
fi
|
||||
|
||||
for file in `find ${workdir} -name go.mod`; do
|
||||
goModPath=$(dirname $file)
|
||||
echo ""
|
||||
echo "processing dir: $goModPath"
|
||||
cd $goModPath
|
||||
go mod tidy
|
||||
go list -f "{{if and (not .Indirect) (not .Main)}}{{.Path}}@${newVersion}{{end}}" -m all | grep "^github.com/gogf/gf"
|
||||
go list -f "{{if and (not .Indirect) (not .Main)}}{{.Path}}@${newVersion}{{end}}" -m all | grep "^github.com/gogf/gf" | xargs -L1 go get -v
|
||||
go mod tidy
|
||||
cd -
|
||||
done
|
||||
|
||||
if [ -f "go.work.${newVersion}" ]; then
|
||||
# File exists, rename it back
|
||||
mv go.work.${newVersion} go.work
|
||||
echo "Restore go.work file"
|
||||
fi
|
||||
59
.github/workflows/tag.yml
vendored
Normal file
59
.github/workflows/tag.yml
vendored
Normal file
@ -0,0 +1,59 @@
|
||||
name: GoFrame AutoCreating SubMod Tags
|
||||
|
||||
on:
|
||||
push:
|
||||
# Sequence of patterns matched against refs/tags
|
||||
tags:
|
||||
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
|
||||
|
||||
env:
|
||||
TZ: Asia/Shanghai
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Auto Creating Tags
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Github Code
|
||||
uses: actions/checkout@v5
|
||||
- name: Auto Creating Tags For Contrib Packages
|
||||
run: |
|
||||
git config --global user.email "tagrobot@goframe.org"
|
||||
git config --global user.name "TagRobot"
|
||||
# auto create tags for contrib packages.
|
||||
for file in `find contrib -name go.mod`; do
|
||||
tag=$(dirname $file)/${{ github.ref_name }}
|
||||
git tag $tag
|
||||
git push origin $tag
|
||||
done
|
||||
- name: update dependencies
|
||||
run: |
|
||||
go env -w GOPRIVATE=github.com/gogf/gf
|
||||
.github/workflows/scripts/update_version.sh ./cmd/gf ${{ github.ref_name }}
|
||||
- name: Create Pull Request
|
||||
uses: peter-evans/create-pull-request@v4
|
||||
with:
|
||||
commit-message: 'update gf cli to ${{ github.ref_name }}'
|
||||
title: 'fix: update gf cli to ${{ github.ref_name }}'
|
||||
base: master
|
||||
branch: fix/${{ github.ref_name }}
|
||||
delete-branch: true
|
||||
- name: Commit & Push changes
|
||||
uses: actions-js/push@master
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
branch: fix/${{ github.ref_name }}
|
||||
author_name: TagRobot
|
||||
author_email: tagrobot@goframe.org
|
||||
message: 'fix: update gf cli to ${{ github.ref_name }}'
|
||||
- name: Auto Creating Tags For cli tool
|
||||
run: |
|
||||
git config --global user.email "tagrobot@goframe.org"
|
||||
git config --global user.name "TagRobot"
|
||||
# auto create tag for cli tool
|
||||
for file in `find cmd -name go.mod -not -path "*/testdata/*"`; do
|
||||
tag=$(dirname $file)/${{ github.ref_name }}
|
||||
git tag $tag
|
||||
git push origin $tag
|
||||
done
|
||||
25
.gitignore
vendored
25
.gitignore
vendored
@ -6,14 +6,23 @@
|
||||
.idea/
|
||||
.settings/
|
||||
.vscode/
|
||||
vender/
|
||||
log/
|
||||
composer.lock
|
||||
gitpush.sh
|
||||
pkg/
|
||||
vendor/
|
||||
bin/
|
||||
cbuild
|
||||
**/.DS_Store
|
||||
.vscode/
|
||||
go.sum
|
||||
.test/
|
||||
cmd/gf/main
|
||||
cmd/gf/gf
|
||||
temp/
|
||||
example/log
|
||||
go.work
|
||||
go.work.sum
|
||||
!cmd/gf/go.work
|
||||
.windsurfrules
|
||||
|
||||
# Ignore for docs
|
||||
node_modules
|
||||
.docusaurus
|
||||
output
|
||||
.example/
|
||||
.golangci.bck.yml
|
||||
*.exe
|
||||
0
.gitmodules
vendored
Normal file
0
.gitmodules
vendored
Normal file
219
.golangci.yml
Normal file
219
.golangci.yml
Normal file
@ -0,0 +1,219 @@
|
||||
version: "2"
|
||||
run:
|
||||
concurrency: 4
|
||||
modules-download-mode: readonly
|
||||
issues-exit-code: 2
|
||||
tests: false
|
||||
allow-parallel-runners: true
|
||||
allow-serial-runners: true
|
||||
linters:
|
||||
default: none
|
||||
enable:
|
||||
- errcheck
|
||||
- errchkjson
|
||||
- funlen
|
||||
- goconst
|
||||
- gocritic
|
||||
- govet
|
||||
- misspell
|
||||
- nolintlint
|
||||
- revive
|
||||
- staticcheck
|
||||
- usestdlibvars
|
||||
- whitespace
|
||||
settings:
|
||||
funlen:
|
||||
lines: 340
|
||||
statements: -1
|
||||
goconst:
|
||||
match-constant: false
|
||||
min-len: 4
|
||||
min-occurrences: 30
|
||||
numbers: true
|
||||
min: 5
|
||||
max: 20
|
||||
ignore-calls: false
|
||||
gocritic:
|
||||
disabled-checks:
|
||||
- ifElseChain
|
||||
- assignOp
|
||||
- appendAssign
|
||||
- singleCaseSwitch
|
||||
- regexpMust
|
||||
- typeSwitchVar
|
||||
- elseif
|
||||
govet:
|
||||
disable:
|
||||
- asmdecl
|
||||
- assign
|
||||
- atomic
|
||||
- atomicalign
|
||||
- bools
|
||||
- buildtag
|
||||
- cgocall
|
||||
- composites
|
||||
- copylocks
|
||||
- deepequalerrors
|
||||
- errorsas
|
||||
- fieldalignment
|
||||
- findcall
|
||||
- framepointer
|
||||
- httpresponse
|
||||
- ifaceassert
|
||||
- loopclosure
|
||||
- lostcancel
|
||||
- nilfunc
|
||||
- nilness
|
||||
- reflectvaluecompare
|
||||
- shift
|
||||
- shadow
|
||||
- sigchanyzer
|
||||
- sortslice
|
||||
- stdmethods
|
||||
- stringintconv
|
||||
- structtag
|
||||
- testinggoroutine
|
||||
- tests
|
||||
- unmarshal
|
||||
- unreachable
|
||||
- unsafeptr
|
||||
- unusedwrite
|
||||
enable-all: true
|
||||
settings:
|
||||
printf:
|
||||
funcs:
|
||||
- (github.com/golangci/golangci-lint/pkg/logutils.Log).Infof
|
||||
- (github.com/golangci/golangci-lint/pkg/logutils.Log).Warnf
|
||||
- (github.com/golangci/golangci-lint/pkg/logutils.Log).Errorf
|
||||
- (github.com/golangci/golangci-lint/pkg/logutils.Log).Fatalf
|
||||
unusedresult:
|
||||
funcs:
|
||||
- pkg.MyFunc
|
||||
- context.WithCancel
|
||||
stringmethods:
|
||||
- MyMethod
|
||||
misspell:
|
||||
locale: US
|
||||
ignore-rules:
|
||||
- cancelled
|
||||
revive:
|
||||
severity: error
|
||||
rules:
|
||||
- name: atomic
|
||||
- name: line-length-limit
|
||||
arguments:
|
||||
- 380
|
||||
severity: error
|
||||
- name: unhandled-error
|
||||
severity: warning
|
||||
disabled: true
|
||||
- name: var-naming
|
||||
arguments:
|
||||
- - ID
|
||||
- URL
|
||||
- IP
|
||||
- HTTP
|
||||
- JSON
|
||||
- API
|
||||
- UID
|
||||
- Id
|
||||
- Api
|
||||
- Uid
|
||||
- Http
|
||||
- Json
|
||||
- Ip
|
||||
- Url
|
||||
- - VM
|
||||
severity: warning
|
||||
disabled: true
|
||||
- name: string-format
|
||||
arguments:
|
||||
- - core.WriteError[1].Message
|
||||
- /^([^A-Z]|$)/
|
||||
- must not start with a capital letter
|
||||
- - fmt.Errorf[0]
|
||||
- /(^|[^\.!?])$/
|
||||
- must not end in punctuation
|
||||
- - panic
|
||||
- /^[^\n]*$/
|
||||
- must not contain line breaks
|
||||
severity: warning
|
||||
disabled: false
|
||||
- name: function-result-limit
|
||||
arguments:
|
||||
- 4
|
||||
severity: warning
|
||||
disabled: false
|
||||
staticcheck:
|
||||
checks: [ "all","-S1000","-S1009","-S1016","-S1023","-S1025","-S1029","-S1034","-S1040","-SA1016","-SA1019","-SA1029","-SA4006","-SA4015","-SA6003","-SA9003","-ST1003","-QF1001","-QF1002","-QF1003","-QF1006","-QF1007","-QF1008","-QF1011","-QF1012","-ST1011" ]
|
||||
initialisms: [ "ACL", "API", "ASCII", "CPU", "CSS", "DNS", "EOF", "GUID", "HTML", "HTTP", "HTTPS", "ID", "IP", "JSON", "QPS", "RAM", "RPC", "SLA", "SMTP", "SQL", "SSH", "TCP", "TLS", "TTL", "UDP", "UI", "GID", "UID", "UUID", "URI", "URL", "UTF8", "VM", "XML", "XMPP", "XSRF", "XSS", "SIP", "RTP", "AMQP", "DB", "TS" ]
|
||||
dot-import-whitelist: [ "fmt" ]
|
||||
http-status-code-whitelist: [ "200", "400", "404", "500" ]
|
||||
exclusions:
|
||||
generated: lax
|
||||
presets:
|
||||
- comments
|
||||
- common-false-positives
|
||||
- legacy
|
||||
- std-error-handling
|
||||
rules:
|
||||
- linters:
|
||||
- revive
|
||||
path: _test\.go
|
||||
text: context.Context should be the first parameter of a function
|
||||
- linters:
|
||||
- revive
|
||||
path: _test\.go
|
||||
text: exported func.*returns unexported type.*which can be annoying to use
|
||||
- linters:
|
||||
- gocritic
|
||||
text: 'unnecessaryDefer:'
|
||||
- linters:
|
||||
- goconst
|
||||
path: (.+)_test\.go
|
||||
paths:
|
||||
- third_party$
|
||||
- builtin$
|
||||
- examples$
|
||||
formatters:
|
||||
enable:
|
||||
- gci
|
||||
- gofmt
|
||||
- goimports
|
||||
settings:
|
||||
gci:
|
||||
sections:
|
||||
- standard
|
||||
- blank
|
||||
- default
|
||||
- dot
|
||||
- prefix(github.com/gogf/gf/v2)
|
||||
- prefix(github.com/gogf/gf/cmd)
|
||||
- prefix(github.com/gogf/gfcontrib)
|
||||
- prefix(github.com/gogf/gf/example)
|
||||
custom-order: true
|
||||
no-lex-order: false
|
||||
gofmt:
|
||||
simplify: true
|
||||
rewrite-rules:
|
||||
- pattern: 'interface{}'
|
||||
replacement: 'any'
|
||||
- pattern: 'reflect.Ptr'
|
||||
replacement: 'reflect.Pointer'
|
||||
- pattern: 'ioutil.ReadAll'
|
||||
replacement: 'io.ReadAll'
|
||||
- pattern: 'ioutil.WriteFile'
|
||||
replacement: 'os.WriteFile'
|
||||
- pattern: 'ioutil.ReadFile'
|
||||
replacement: 'os.ReadFile'
|
||||
- pattern: 'ioutil.NopCloser'
|
||||
replacement: 'io.NopCloser'
|
||||
goimports:
|
||||
local-prefixes:
|
||||
- github.com/gogf/gf/v2
|
||||
exclusions:
|
||||
generated: lax
|
||||
paths:
|
||||
- third_party$
|
||||
- builtin$
|
||||
- examples$
|
||||
46
.make_tidy.sh
Executable file
46
.make_tidy.sh
Executable file
@ -0,0 +1,46 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Function to run sed in-place with OS-specific options
|
||||
sed_replace() {
|
||||
if [[ "$OSTYPE" == "darwin"* ]]; then
|
||||
# macOS - requires empty string after -i
|
||||
sed -i '' "$@"
|
||||
else
|
||||
# Linux/Windows Git Bash
|
||||
sed -i "$@"
|
||||
fi
|
||||
}
|
||||
|
||||
workdir=.
|
||||
echo "Prepare to tidy all go.mod files in the ${workdir} directory"
|
||||
|
||||
# check find command support or not
|
||||
output=$(find "${workdir}" -name go.mod 2>&1)
|
||||
if [[ $? -ne 0 ]]; then
|
||||
echo "Error: please use bash or zsh to run!"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
for file in `find ${workdir} -name go.mod`; do
|
||||
goModPath=$(dirname $file)
|
||||
echo ""
|
||||
echo "processing dir: $goModPath"
|
||||
|
||||
if [[ $goModPath =~ "/testdata/" ]]; then
|
||||
echo "ignore testdata path $goModPath"
|
||||
continue 1
|
||||
fi
|
||||
|
||||
if [[ $goModPath =~ "/examples/" ]]; then
|
||||
echo "ignore examples path $goModPath"
|
||||
continue 1
|
||||
fi
|
||||
|
||||
cd $goModPath
|
||||
# Remove indirect dependencies
|
||||
sed_replace '/\/\/ indirect/d' go.mod
|
||||
go mod tidy
|
||||
# Remove toolchain line if exists
|
||||
sed_replace '/^toolchain/d' go.mod
|
||||
cd - > /dev/null
|
||||
done
|
||||
114
.make_version.sh
Executable file
114
.make_version.sh
Executable file
@ -0,0 +1,114 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Function to run sed in-place with OS-specific options
|
||||
sed_replace() {
|
||||
if [[ "$OSTYPE" == "darwin"* ]]; then
|
||||
# macOS - requires empty string after -i
|
||||
sed -i '' "$@"
|
||||
else
|
||||
# Linux/Windows Git Bash
|
||||
sed -i "$@"
|
||||
fi
|
||||
}
|
||||
|
||||
if [ $# -ne 2 ]; then
|
||||
echo "Parameter exception, please execute in the format of $0 [directory] [version number]"
|
||||
echo "PS:$0 ./ v2.4.0"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -d "$1" ]; then
|
||||
echo "Error: Directory does not exist"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ "$2" != v* ]]; then
|
||||
echo "Error: Version number must start with v"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
workdir=.
|
||||
newVersion=$2
|
||||
echo "Prepare to replace the GoFrame library version numbers in all go.mod files in the ${workdir} directory with ${newVersion}"
|
||||
|
||||
# check find command support or not
|
||||
output=$(find "${workdir}" -name go.mod 2>&1)
|
||||
if [[ $? -ne 0 ]]; then
|
||||
echo "Error: please use bash or zsh to run!"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ true ]]; then
|
||||
# Use sed to replace the version number in version.go
|
||||
sed_replace 's/VERSION = ".*"/VERSION = "'${newVersion}'"/' version.go
|
||||
|
||||
# Use sed to replace the version number in README.MD
|
||||
sed_replace 's/version=[^"]*/version='${newVersion}'/' README.MD
|
||||
sed_replace 's/version=[^"]*/version='${newVersion}'/' README.zh_CN.MD
|
||||
fi
|
||||
|
||||
if [ -f "go.work" ]; then
|
||||
mv go.work go.work.version.bak
|
||||
echo "Back up the go.work file to avoid affecting the upgrade"
|
||||
fi
|
||||
|
||||
for file in `find ${workdir} -name go.mod`; do
|
||||
goModPath=$(dirname $file)
|
||||
echo ""
|
||||
echo "processing dir: $goModPath"
|
||||
|
||||
if [[ $goModPath =~ "/testdata/" ]]; then
|
||||
echo "ignore testdata path $goModPath"
|
||||
continue 1
|
||||
fi
|
||||
|
||||
if [[ $goModPath =~ "/examples/" ]]; then
|
||||
echo "ignore examples path $goModPath"
|
||||
continue 1
|
||||
fi
|
||||
|
||||
cd $goModPath
|
||||
|
||||
# Add replace directive for local development.
|
||||
if [ $goModPath = "./cmd/gf" ]; then
|
||||
mv go.work go.work.version.bak
|
||||
go mod edit -replace github.com/gogf/gf/v2=../../
|
||||
go mod edit -replace github.com/gogf/gf/contrib/drivers/clickhouse/v2=../../contrib/drivers/clickhouse
|
||||
go mod edit -replace github.com/gogf/gf/contrib/drivers/mssql/v2=../../contrib/drivers/mssql
|
||||
go mod edit -replace github.com/gogf/gf/contrib/drivers/mysql/v2=../../contrib/drivers/mysql
|
||||
go mod edit -replace github.com/gogf/gf/contrib/drivers/oracle/v2=../../contrib/drivers/oracle
|
||||
go mod edit -replace github.com/gogf/gf/contrib/drivers/pgsql/v2=../../contrib/drivers/pgsql
|
||||
go mod edit -replace github.com/gogf/gf/contrib/drivers/sqlite/v2=../../contrib/drivers/sqlite
|
||||
fi
|
||||
# Remove indirect dependencies
|
||||
sed_replace '/\/\/ indirect/d' go.mod
|
||||
go mod tidy
|
||||
# Remove toolchain line if exists
|
||||
sed_replace '/^toolchain/d' go.mod
|
||||
|
||||
# Upgrading only GoFrame related libraries, sometimes even if a version number is specified,
|
||||
# it may not be possible to successfully upgrade. Please confirm before submitting the code
|
||||
go list -f "{{if and (not .Indirect) (not .Main)}}{{.Path}}@${newVersion}{{end}}" -m all | grep "^github.com/gogf/gf"
|
||||
go list -f "{{if and (not .Indirect) (not .Main)}}{{.Path}}@${newVersion}{{end}}" -m all | grep "^github.com/gogf/gf" | xargs -L1 go get -v
|
||||
# Remove indirect dependencies
|
||||
sed_replace '/\/\/ indirect/d' go.mod
|
||||
go mod tidy
|
||||
# Remove toolchain line if exists
|
||||
sed_replace '/^toolchain/d' go.mod
|
||||
if [ $goModPath = "./cmd/gf" ]; then
|
||||
go mod edit -dropreplace github.com/gogf/gf/v2
|
||||
go mod edit -dropreplace github.com/gogf/gf/contrib/drivers/clickhouse/v2
|
||||
go mod edit -dropreplace github.com/gogf/gf/contrib/drivers/mssql/v2
|
||||
go mod edit -dropreplace github.com/gogf/gf/contrib/drivers/mysql/v2
|
||||
go mod edit -dropreplace github.com/gogf/gf/contrib/drivers/oracle/v2
|
||||
go mod edit -dropreplace github.com/gogf/gf/contrib/drivers/pgsql/v2
|
||||
go mod edit -dropreplace github.com/gogf/gf/contrib/drivers/sqlite/v2
|
||||
mv go.work.version.bak go.work
|
||||
fi
|
||||
cd -
|
||||
done
|
||||
|
||||
if [ -f "go.work.version.bak" ]; then
|
||||
mv go.work.version.bak go.work
|
||||
echo "Restore the go.work file"
|
||||
fi
|
||||
39
.travis.yml
39
.travis.yml
@ -1,39 +0,0 @@
|
||||
language: go
|
||||
|
||||
go:
|
||||
- "1.10.x"
|
||||
- "1.11.x"
|
||||
- "1.12.x"
|
||||
|
||||
branches:
|
||||
only:
|
||||
- master
|
||||
- develop
|
||||
|
||||
env:
|
||||
- GO111MODULE=on
|
||||
|
||||
services:
|
||||
- mysql
|
||||
- redis-server
|
||||
|
||||
addons:
|
||||
hosts:
|
||||
- local
|
||||
|
||||
before_install:
|
||||
- pwd
|
||||
|
||||
install:
|
||||
- cat /etc/hosts
|
||||
|
||||
script:
|
||||
- cd g
|
||||
- GOARCH=386 go test -v ./...
|
||||
- GOARCH=amd64 go test -v ./... -race -coverprofile=coverage.txt -covermode=atomic
|
||||
|
||||
after_success:
|
||||
- bash <(curl -s https://codecov.io/bash)
|
||||
|
||||
|
||||
|
||||
211
CLAUDE.md
Normal file
211
CLAUDE.md
Normal file
@ -0,0 +1,211 @@
|
||||
# Repository Overview
|
||||
|
||||
This is the [GoFrame](https://goframe.org) framework (`github.com/gogf/gf/v2`) — a modular Go application framework. The repository is a **multi-module monorepo**: the root module hosts the core framework, while `cmd/gf` and every directory under `contrib/` are independent Go modules with their own `go.mod`.
|
||||
|
||||
- Root module: `github.com/gogf/gf/v2` (Go 1.23+)
|
||||
- Tooling module: `cmd/gf` (CLI: `gf` command, separate `go.work`)
|
||||
- Plugin modules under `contrib/`: `config/*`, `drivers/*` (mysql, pgsql, mssql, oracle, sqlite, clickhouse, dm, gaussdb, mariadb, oceanbase, tidb, sqlitecgo), `metric/*`, `nosql/*`, `registry/*`, `rpc/grpcx`, `sdk/*`, `trace/*`. Each is published as its own module so users only pull what they need.
|
||||
|
||||
The root framework intentionally has **minimal external dependencies** (see `go.mod`). Anything requiring a heavy third-party dep (a DB driver, a registry client, an RPC stack) lives in `contrib/`.
|
||||
|
||||
## Top-level package map
|
||||
|
||||
| Path | Purpose |
|
||||
| --- | --- |
|
||||
| `frame/g`, `frame/gins` | Convenience facade (`g.Server()`, `g.DB()`, `g.Cfg()`) and the singleton/instance container |
|
||||
| `net/` | `ghttp` (HTTP server/router), `gclient` (HTTP client), `gtcp`, `gudp`, `gsel` (load balancing), `gsvc` (service discovery), `gtrace`, `goai` (OpenAPI) |
|
||||
| `os/` | OS abstractions: `gcfg` (config), `gcmd` (CLI), `gcron`, `glog`, `gfile`, `gres` (resource embedding), `gview` (templating), `gcache`, `gsession`, `gctx`, `gtimer`, `gproc`, `gmetric`, `gfsnotify`, `gstructs` |
|
||||
| `database/` | `gdb` (ORM/query builder, driver-agnostic core), `gredis` (Redis client core) |
|
||||
| `container/` | Concurrent-safe data structures: `garray`, `gmap`, `gset`, `gtree`, `glist`, `gqueue`, `gring`, `gpool`, `gtype`, `gvar` |
|
||||
| `encoding/` | Codecs for JSON/XML/YAML/TOML/INI/Properties, base64, charsets, compression, hashes, HTML, URL |
|
||||
| `text/` | `gstr`, `gregex` |
|
||||
| `util/` | `gconv` (universal conversion — heavily used), `gvalid` (validation), `gutil`, `grand`, `guid`, `gtag`, `gmeta`, `gpage`, `gmode` |
|
||||
| `crypto/` | `gaes`, `gdes`, `grsa`, `gmd5`, `gsha*`, `gcrc32` |
|
||||
| `errors/` | `gerror` (stack-aware errors), `gcode` (error code registry) |
|
||||
| `internal/` | Framework-internal helpers (do not import from outside the root module) |
|
||||
| `test/gtest` | The framework's own testing helpers — used throughout the test suite |
|
||||
|
||||
Concrete database drivers and Redis adapters live under `contrib/drivers/` and `contrib/nosql/`; the `database/gdb` and `database/gredis` packages define the abstract layer.
|
||||
|
||||
# Common Commands
|
||||
|
||||
All commands run from the repository root unless noted.
|
||||
|
||||
## Build / lint / tidy
|
||||
|
||||
```bash
|
||||
# Tidy every go.mod in the repo (root, cmd/gf, contrib/*) — strips // indirect and toolchain lines
|
||||
make tidy
|
||||
|
||||
# Run the project's golangci-lint config (.golangci.yml)
|
||||
make lint
|
||||
# Equivalent: golangci-lint run -c .golangci.yml
|
||||
```
|
||||
|
||||
`make tidy` invokes `.make_tidy.sh`, which `cd`s into every directory containing a `go.mod` (skipping `testdata/` and `examples/`) and runs `go mod tidy`. After editing imports in any module, run this from the repo root.
|
||||
|
||||
## Tests
|
||||
|
||||
Each Go module must be tested from inside its own directory because they are separate modules. The CI script (`.github/workflows/scripts/ci-main.sh`) iterates every `go.mod`:
|
||||
|
||||
```bash
|
||||
# Build + race-enabled tests for the root module
|
||||
go build ./...
|
||||
go test ./... -count=1 -race
|
||||
|
||||
# Coverage (matches CI 'coverage' mode)
|
||||
go test ./... -count=1 -race -coverprofile=coverage.out -covermode=atomic \
|
||||
-coverpkg=./...,github.com/gogf/gf/...
|
||||
|
||||
# Run a single package's tests
|
||||
go test -count=1 -race ./os/gcfg/...
|
||||
|
||||
# Run a single test by name
|
||||
go test -count=1 -race -run TestCfg_Get ./os/gcfg/
|
||||
|
||||
# Test a contrib module — must cd in first (separate go.mod)
|
||||
cd contrib/drivers/mysql && go test ./... -count=1 -race
|
||||
```
|
||||
|
||||
Many tests (database drivers, registry clients, redis cluster, apollo/nacos config) require backing services. CI starts them via docker-compose files under `.github/workflows/{redis,apollo,nacos,consul}/`. Locally, use:
|
||||
|
||||
```bash
|
||||
make docker # start the default local stack
|
||||
make docker cmd=start svc=mysql # start a specific service
|
||||
make docker cmd=stop svc=mysql
|
||||
```
|
||||
|
||||
## CLI tool
|
||||
|
||||
```bash
|
||||
cd cmd/gf && go run . <subcommand> # iterate on the gf CLI itself
|
||||
```
|
||||
|
||||
# Architecture Notes Worth Knowing Up Front
|
||||
|
||||
- **The `frame/g` package is a facade, not a library.** It re-exports types and provides singleton accessors (`g.DB()`, `g.Server()`, `g.Cfg()`, `g.Log()`) backed by `frame/gins`. Examples in docs use `g.*` heavily; framework-internal code generally imports the underlying packages directly.
|
||||
- **`util/gconv` is foundational.** Most public APIs accept `any` and use `gconv` for type coercion. When changing argument handling, search for `gconv.` usage to understand the conversion contract.
|
||||
- **`gdb` is driver-agnostic.** The core in `database/gdb` exposes interfaces; concrete drivers (`contrib/drivers/mysql`, etc.) register themselves via `init()` when imported. The same model pattern applies to `gredis`, `gcfg` (apollo/nacos/polaris adapters), and `gsvc` (etcd/consul/nacos/polaris/zookeeper registries).
|
||||
- **`internal/` is private.** Sub-packages (`intlog`, `instance`, `reflection`, `utils`, `json`, `command`) are not part of the public API surface — do not import them from outside the root module, and avoid leaking their types in exported signatures.
|
||||
- **Tests use `gtest`, not stdlib `testing` directly.** `test/gtest` provides `gtest.C(t, func(t *gtest.T){...})` blocks, fluent assertions (`t.Assert`, `t.AssertNE`, `t.AssertNil`), and is the project-wide convention. Match this style when adding tests.
|
||||
- **CI matrix.** Tests run on Go 1.23, 1.24, 1.25 across 386 and amd64. `contrib/*` only runs on the latest Go version (`LATEST_GO_VERSION` in `.github/workflows/ci-main.yml`). Code that requires the latest stdlib should live in `contrib/` or be guarded.
|
||||
- **Lint config matters.** `.golangci.yml` enforces a 380-char line limit, function length up to 340 lines, custom import grouping (`gci` with `prefix(github.com/gogf/gf/v2)` ahead of `cmd`/`contrib`/`example`), `gofmt -s` with rewrites (`interface{}` → `any`, `ioutil.*` → `io`/`os`, `reflect.Ptr` → `reflect.Pointer`). Run `make lint` before pushing.
|
||||
- **OpenSpec changes live under `openspec/changes/`** and drive every non-trivial change through the workflow defined below. The active iteration directory must be checked before starting work — see the Development Workflow Rules section.
|
||||
|
||||
# Karpathy Guidelines
|
||||
|
||||
**Tradeoff:** These guidelines bias toward caution over speed. For trivial tasks, use judgment.
|
||||
|
||||
## 1. Think Before Coding
|
||||
|
||||
**Don't assume. Don't hide confusion. Surface tradeoffs.**
|
||||
|
||||
Before implementing:
|
||||
- State your assumptions explicitly. If uncertain, ask.
|
||||
- If multiple interpretations exist, present them - don't pick silently.
|
||||
- If a simpler approach exists, say so. Push back when warranted.
|
||||
- If something is unclear, stop. Name what's confusing. Ask.
|
||||
|
||||
## 2. Simplicity First
|
||||
|
||||
**Minimum code that solves the problem. Nothing speculative.**
|
||||
|
||||
- No features beyond what was asked.
|
||||
- No abstractions for single-use code.
|
||||
- No "flexibility" or "configurability" that wasn't requested.
|
||||
- No error handling for impossible scenarios.
|
||||
- If you write 200 lines and it could be 50, rewrite it.
|
||||
|
||||
Ask yourself: "Would a senior engineer say this is overcomplicated?" If yes, simplify.
|
||||
|
||||
## 3. Surgical Changes
|
||||
|
||||
**Touch only what you must. Clean up only your own mess.**
|
||||
|
||||
When editing existing code:
|
||||
- Don't "improve" adjacent code, comments, or formatting.
|
||||
- Don't refactor things that aren't broken.
|
||||
- Match existing style, even if you'd do it differently.
|
||||
- If you notice unrelated dead code, mention it - don't delete it.
|
||||
|
||||
When your changes create orphans:
|
||||
- Remove imports/variables/functions that YOUR changes made unused.
|
||||
- Don't remove pre-existing dead code unless asked.
|
||||
|
||||
The test: Every changed line should trace directly to the user's request.
|
||||
|
||||
## 4. Goal-Driven Execution
|
||||
|
||||
**Define success criteria. Loop until verified.**
|
||||
|
||||
Transform tasks into verifiable goals:
|
||||
- "Add validation" → "Write tests for invalid inputs, then make them pass"
|
||||
- "Fix the bug" → "Write a test that reproduces it, then make it pass"
|
||||
- "Refactor X" → "Ensure tests pass before and after"
|
||||
|
||||
For multi-step tasks, state a brief plan:
|
||||
```
|
||||
1. [Step] → verify: [check]
|
||||
2. [Step] → verify: [check]
|
||||
3. [Step] → verify: [check]
|
||||
```
|
||||
|
||||
Strong success criteria let you loop independently. Weak criteria ("make it work") require constant clarification.
|
||||
|
||||
# Documentation Writing Rules
|
||||
|
||||
Technical documentation such as `README.md` must follow `.agents/instructions/markdown-format.instructions.md`.
|
||||
|
||||
- All directory-level primary documentation files in the repository must use the English `README.md` and provide a matching Chinese mirror in `README.zh_CN.md`.
|
||||
- When adding a new directory documentation file, create both `README.md` and `README.zh_CN.md` in the same change. Maintaining only one language version is not allowed.
|
||||
|
||||
# Development Workflow Rules
|
||||
|
||||
This project follows `SDD` and uses the `OpenSpec` tool to drive implementation. Change records are stored under `openspec/changes/`. Each change includes `proposal.md`, `design.md`, `specs/`, and `tasks.md`.
|
||||
|
||||
**Execution workflow**:
|
||||
1. Use the `/opsx:explore` slash command at `.agents/prompts/opsx/explore.md` to conduct an exploratory discussion based on the requirement description, analyze the problem, design the solution, and assess risks.
|
||||
2. Once the exploratory discussion finishes and the solution is clear, use the `/opsx:propose` slash command at `.agents/prompts/opsx/propose.md` to turn it into a formal `OpenSpec` change proposal. The command format is `/opsx:propose feature-name`, where `feature-name` is a descriptive name for the current change in `kebab-case`, such as `user-auth` or `data-export`. A new change directory will then be generated automatically under `openspec/changes`, containing incremental spec documents (`spec/`), the technical implementation plan (`design.md`), the proposal and rationale (`proposal.md`), and the implementation task list (`tasks.md`).
|
||||
3. Then run the `/opsx:apply` slash command at `.agents/prompts/opsx/apply.md` to execute the items in `tasks.md` one by one, completing code changes, tests, and documentation updates. After the work is done, the `/gf-review` skill must be invoked for code and spec review.
|
||||
4. When users report issues or improvement requests, the `/gf-feedback` skill must be used to fix and verify them, and the related `OpenSpec` documents must be updated. After the work is done, the `/gf-review` skill must be invoked for review.
|
||||
5. After the user confirms that the current iteration is complete and has no remaining issues, run the `/opsx:archive` slash command at `.agents/prompts/opsx/archive.md` to archive the change. Before archiving, the `/gf-review` skill must be used for a full change review to ensure code quality and compliance with the spec.
|
||||
|
||||
**Key rules**:
|
||||
- **An `OpenSpec` change is considered active until it is archived**: any change directory that still exists directly under `openspec/changes/` and has **not been moved to** `openspec/changes/archive/` is an active change. **Even if the change has completed all tasks and `openspec list --json` shows `status: complete`, it must still be treated as active until the archive step has been executed.**
|
||||
- When a user reports a bug, defect, or improvement request in either Chinese or English, and there is an active `OpenSpec` change in the project, the `gf-feedback` skill must be used. **Unless the user explicitly asks to create a new change, the feedback must always be appended to the current active iteration, even if it is unrelated to the main feature of that iteration**, so that everything can be managed and archived together.
|
||||
- The `/gf-review` review skill is triggered automatically after `/opsx:apply` completes, after `/opsx:feedback` completes, and before `/opsx:archive`.
|
||||
- During development tasks executed with tools such as `Claude Code` or `Codex CLI`, if the work can be parallelized effectively with `SubAgent` and doing so would clearly improve efficiency, that option must be evaluated first and adopted whenever appropriate. Only skip `SubAgent` when the task is strongly dependent on serial context, the split cost is too high, or it introduces obvious collaboration risk.
|
||||
- When creating new iteration documents, the content of `proposal.md`, `design.md`, `tasks.md`, and the incremental specs must be written in English.
|
||||
|
||||
# Code Development Rules
|
||||
- All source code must include comments, such as package comments, file comments, method comments for both public and private methods, constant comments, variable comments, and comments for key logic.
|
||||
- **All submitted code changes must include unit tests**: every submitted code change must add or update focused unit tests that directly cover the affected logic and expected behavior of the changed code path, and the coverage for newly added code must stay at or above 80%; 90% or above is the preferred target when feasible.
|
||||
- **Do not hardcode string literals with enum semantics in backend implementation code**: values that represent statuses, types, stages, actions, execution modes, sort directions, filter operators, or any other enum-like semantics must be managed through Go named types and constants. Writing raw string literals directly in business branching, comparisons, assignments, or persistence logic is forbidden.
|
||||
- **Do not ignore any `error` return value**: every call that may return an `error` must be handled explicitly. Do not use patterns such as `_ = someFunc()`, `_, _ = someFunc()`, or direct calls that discard returned errors. In business flows, errors should be returned explicitly or converted before returning; in initialization, startup, or other critical non-recoverable paths, they should `panic`; in tests and cleanup paths, they must still be asserted, logged, or otherwise handled explicitly rather than silently ignored.
|
||||
- **Do not use stand-alone assignments like `_ = var` to mask unused parameters or local variables**: this placeholder pattern has no business meaning and creates misleading signals about whether the variable was supposed to participate in the logic. Prefer deleting unused variables. If a parameter must be kept to satisfy an interface signature or callback contract, use the blank identifier directly in the function signature, such as `func(ctx context.Context, _ gdb.TX) error`, or omit an unused receiver name instead of adding one-line statements like `_ = tx`, `_ = req`, or `_ = ctx` in the function body.
|
||||
- **File header comment rules**:
|
||||
- Every `Go` source file must include a file-purpose comment at the top of the file. Component-level comments should appear in the component's main file, meaning the file with the same name as the component, such as `plugin.go`, `config.go`, or `file.go`.
|
||||
- In a main file, the component comment must be placed immediately before the `package xxx` declaration with no blank line in between. For example:
|
||||
```go
|
||||
// Package plugin implements plugin manifest discovery, lifecycle orchestration,
|
||||
// governance metadata synchronization, and host integration for LinaPro plugins.
|
||||
package plugin
|
||||
```
|
||||
- Other implementation files must keep only file comments that describe the responsibility of the current file, such as `plugin_xxx.go` or `config_xxx.go`. There must be one blank line between the file comment and `package xxx`, and non-main files must not duplicate component-level descriptions.
|
||||
- **Variable Declarations**: When defining multiple variables, use a `var` block to group them for better alignment and readability:
|
||||
```go
|
||||
// Good - aligned and clean
|
||||
var (
|
||||
authSvc *auth.Service
|
||||
bizCtxSvc *bizctx.Service
|
||||
k8sSvc *svcK8s.Service
|
||||
notebookSvc *notebook.Service
|
||||
middlewareSvc *middleware.Service
|
||||
)
|
||||
|
||||
// Avoid - scattered declarations
|
||||
authSvc := auth.New()
|
||||
bizCtxSvc := bizctx.New()
|
||||
k8sSvc := svcK8s.New()
|
||||
```
|
||||
Apply this pattern when you have 3 or more related variable declarations in the same scope.
|
||||
17
CONTRIBUTING.md
Normal file
17
CONTRIBUTING.md
Normal file
@ -0,0 +1,17 @@
|
||||
# Contributing
|
||||
|
||||
Thanks for taking the time to join our community and start contributing!
|
||||
|
||||
## With issues
|
||||
|
||||
- Use the search tool before opening a new issue.
|
||||
- Please provide source code and commit sha if you found a bug.
|
||||
- Review existing issues and provide feedback or react to them.
|
||||
|
||||
## With pull requests
|
||||
|
||||
- Open your pull request against `master`
|
||||
- Your pull request should have no more than two commits, if not you should squash them.
|
||||
- It should pass all tests in the available continuous integrations systems such as GitHub CI.
|
||||
- You should add/modify tests to cover your proposed code changes.
|
||||
- If your pull request contains a new feature, please document it on the README.
|
||||
2
LICENSE
2
LICENSE
@ -1,6 +1,6 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2017 john@goframe.org https://goframe.org
|
||||
Copyright (c) 2017 GoFrame Team https://goframe.org
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
|
||||
64
Makefile
Normal file
64
Makefile
Normal file
@ -0,0 +1,64 @@
|
||||
SHELL := /bin/bash
|
||||
|
||||
# execute "go mod tidy" on all folders that have go.mod file
|
||||
.PHONY: tidy
|
||||
tidy:
|
||||
./.make_tidy.sh
|
||||
|
||||
# execute "golangci-lint" to check code style
|
||||
# go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@latest
|
||||
.PHONY: lint
|
||||
lint:
|
||||
golangci-lint run -c .golangci.yml
|
||||
|
||||
# make branch to=v2.4.0
|
||||
.PHONY: branch
|
||||
branch:
|
||||
@set -e; \
|
||||
newVersion=$(to); \
|
||||
if [ -z "$$newVersion" ]; then \
|
||||
echo "Error: 'to' variable is required. Usage: make branch to=vX.Y.Z"; \
|
||||
exit 1; \
|
||||
fi; \
|
||||
branchName=fix/$$newVersion; \
|
||||
echo "Switching to master branch..."; \
|
||||
git checkout master; \
|
||||
echo "Pulling latest changes from master..."; \
|
||||
git pull origin master; \
|
||||
echo "Creating and switching to branch $$branchName from master..."; \
|
||||
git checkout -b $$branchName; \
|
||||
echo "Branch $$branchName created successfully!"
|
||||
|
||||
# make version to=v2.4.0
|
||||
.PHONY: version
|
||||
version:
|
||||
@set -e; \
|
||||
newVersion=$(to); \
|
||||
$(MAKE) -C cmd/gf pack; \
|
||||
./.make_version.sh ./ $$newVersion; \
|
||||
echo "make version to=$(to) done"
|
||||
|
||||
# make tag to=v2.4.0
|
||||
.PHONY: tag
|
||||
tag:
|
||||
@set -e; \
|
||||
newVersion=$(to); \
|
||||
echo "Switching to master branch..."; \
|
||||
git checkout master; \
|
||||
echo "Pulling latest changes from master..."; \
|
||||
git pull origin master; \
|
||||
echo "Creating annotated tag $$newVersion..."; \
|
||||
git tag -a $$newVersion -m "Release $$newVersion"; \
|
||||
echo "Pushing tag $$newVersion..."; \
|
||||
git push origin $$newVersion; \
|
||||
echo "Tag $$newVersion created and pushed successfully!"
|
||||
|
||||
# manage docker services for local development
|
||||
# usage: make docker or make docker cmd=start svc=mysql
|
||||
.PHONY: docker
|
||||
docker:
|
||||
@if [ -z "$(cmd)" ]; then \
|
||||
./.github/workflows/scripts/docker-services.sh; \
|
||||
else \
|
||||
./.github/workflows/scripts/docker-services.sh $(cmd) $(svc) $(extra); \
|
||||
fi
|
||||
122
README.MD
122
README.MD
@ -1,100 +1,54 @@
|
||||
# GoFrame
|
||||
<img align="right" height="150px" src="https://goframe.org/cover.png">
|
||||
English | [简体中文](README.zh_CN.MD)
|
||||
|
||||
[](https://godoc.org/github.com/gogf/gf)
|
||||
[](https://travis-ci.org/gogf/gf)
|
||||
[](https://goreportcard.com/report/github.com/gogf/gf)
|
||||
[](https://codecov.io/gh/gogf/gf/branch/master)
|
||||
[](https://github.com/gogf/gf)
|
||||
<div align=center>
|
||||
<img src="https://goframe.org/img/logo_full.png" width="300" alt="goframe logo"/>
|
||||
|
||||
[](https://pkg.go.dev/github.com/gogf/gf/v2)
|
||||
[](https://github.com/gogf/gf/actions/workflows/ci-main.yml)
|
||||
[](https://scorecard.dev/viewer/?uri=github.com/gogf/gf)
|
||||
[](https://bestpractices.coreinfrastructure.org/projects/9233)
|
||||
[](https://goreportcard.com/report/github.com/gogf/gf/v2)
|
||||
[](https://codecov.io/gh/gogf/gf)
|
||||
[](https://github.com/gogf/gf)
|
||||
[](https://github.com/gogf/gf)
|
||||
|
||||
<!--
|
||||
GoFrame is a modular, loose-coupled, production-ready and most-powerful application development framework of golang. Providing a series of core components and dozens of practical modules, such as: cache, logging, containers, timer, validator, database orm, etc. Supporting web server integrated with router, cookie, session, logger, configure, template, https, hooks, rewrites and many more features.
|
||||
-->
|
||||
[](https://github.com/gogf/gf/releases)
|
||||
[](https://github.com/gogf/gf/pulls)
|
||||
[](https://github.com/gogf/gf/pulls?q=is%3Apr+is%3Aclosed)
|
||||
[](https://github.com/gogf/gf/issues)
|
||||
[](https://github.com/gogf/gf/issues?q=is%3Aissue+is%3Aclosed)
|
||||

|
||||

|
||||
[](https://deepwiki.com/gogf/gf)
|
||||
|
||||
`GF(GoFrame)` is a modular, loose-coupled, production-ready and most-powerful application development framework of golang. Providing a series of core components and dozens of practical modules, such as: memcache, configure, validator, logging, array/queue/set/map containers, timer/timing tasks, file/memory lock, object pool, database ORM, etc. Supporting web server integrated with router, cookie, session, logger, template, https, hooks, rewrites and many more features.
|
||||
|
||||
# Installation
|
||||
```
|
||||
go get -u github.com/gogf/gf
|
||||
```
|
||||
or use `go.mod`:
|
||||
```
|
||||
require github.com/gogf/gf latest
|
||||
```
|
||||
|
||||
# Limitation
|
||||
```
|
||||
golang version >= 1.9.2
|
||||
```
|
||||
|
||||
# Documentation
|
||||
|
||||
* [APIDoc](https://godoc.org/github.com/gogf/gf)
|
||||
* [中文文档](https://goframe.org)
|
||||
|
||||
# Architecture
|
||||
<div align=center>
|
||||
<img src="https://goframe.org/images/arch.png"/>
|
||||
</div>
|
||||
|
||||
# Quick Start
|
||||
A powerful framework for faster, easier, and more efficient project development.
|
||||
|
||||
```go
|
||||
package main
|
||||
## Installation
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/g"
|
||||
"github.com/gogf/gf/g/net/ghttp"
|
||||
)
|
||||
|
||||
func main() {
|
||||
s := g.Server()
|
||||
s.BindHandler("/", func(r *ghttp.Request) {
|
||||
r.Response.Write("Hello World")
|
||||
})
|
||||
s.Run()
|
||||
}
|
||||
```bash
|
||||
go get -u github.com/gogf/gf/v2
|
||||
```
|
||||
|
||||
[View More..](https://goframe.org/start/index)
|
||||
|
||||
|
||||
# License
|
||||
|
||||
`GF` is licensed under the [MIT License](LICENSE), 100% free and open-source, forever.
|
||||
|
||||
# Contributors
|
||||
|
||||
- [aloncn](https://github.com/aloncn)
|
||||
- [chenyang351](https://github.com/chenyang351)
|
||||
- [garfieldkwong](https://gitee.com/garfieldkwong)
|
||||
- [hailaz](https://gitee.com/hailaz)
|
||||
- [johng](https://gitee.com/johng)
|
||||
- [pibigstar](https://github.com/pibigstar)
|
||||
- [qq1054000800](https://gitee.com/qq1054000800)
|
||||
- [wenzi1](https://gitee.com/wenzi1)
|
||||
- [wxkj001](https://github.com/wxkj001)
|
||||
- [ymrjqyy](https://gitee.com/ymrjqyy)
|
||||
- [youyixiao](https://github.com/youyixiao)
|
||||
- [zhangjinfu](https://gitee.com/zhangjinfu)
|
||||
- [zhaopengme](https://github.com/zhaopengme)
|
||||
- [zseeker](https://gitee.com/zseeker)
|
||||
|
||||
# Donators
|
||||
|
||||
- [flyke-xu](https://gitee.com/flyke-xu)
|
||||
- [hailaz](https://gitee.com/hailaz)
|
||||
- [mg91](https://gitee.com/mg91)
|
||||
- [pibigstar](https://github.com/pibigstar)
|
||||
- [tiangenglan](https://gitee.com/tiangenglan)
|
||||
- [wxkj](https://gitee.com/wxkj)
|
||||
- [zhuhuan12](https://gitee.com/zhuhuan12)
|
||||
- [zfan_codes](https://gitee.com/zfan_codes)
|
||||
|
||||
## Documentation
|
||||
|
||||
- Official Site: [https://goframe.org](https://goframe.org)
|
||||
- Official Site(en): [https://goframe.org/en](https://goframe.org/en)
|
||||
- 国内镜像: [https://goframe.org.cn](https://goframe.org.cn)
|
||||
- Mirror Site: [https://pages.goframe.org](https://pages.goframe.org)
|
||||
- Mirror Site: [Offline Docs](https://github.com/gogf/goframe.org-pdf?tab=readme-ov-file#%E6%9C%80%E6%96%B0%E7%89%88%E6%9C%AC)
|
||||
- GoDoc API: [https://pkg.go.dev/github.com/gogf/gf/v2](https://pkg.go.dev/github.com/gogf/gf/v2)
|
||||
- Doc Source: [https://github.com/gogf/gf-site](https://github.com/gogf/gf-site)
|
||||
|
||||
## Contributors
|
||||
|
||||
💖 [Thanks to all the contributors who made GoFrame possible](https://github.com/gogf/gf/graphs/contributors) 💖
|
||||
|
||||
<a href="https://github.com/gogf/gf/graphs/contributors">
|
||||
<img src="https://goframe.org/img/contributors.svg?version=v2.10.2" alt="goframe contributors"/>
|
||||
</a>
|
||||
|
||||
## License
|
||||
|
||||
`GoFrame` is licensed under the [MIT License](LICENSE), 100% free and open-source, forever.
|
||||
|
||||
54
README.zh_CN.MD
Normal file
54
README.zh_CN.MD
Normal file
@ -0,0 +1,54 @@
|
||||
[English](README.MD) | 简体中文
|
||||
|
||||
<div align=center>
|
||||
<img src="https://goframe.org/img/logo_full.png" width="300" alt="goframe logo"/>
|
||||
|
||||
[](https://pkg.go.dev/github.com/gogf/gf/v2)
|
||||
[](https://github.com/gogf/gf/actions/workflows/ci-main.yml)
|
||||
[](https://scorecard.dev/viewer/?uri=github.com/gogf/gf)
|
||||
[](https://bestpractices.coreinfrastructure.org/projects/9233)
|
||||
[](https://goreportcard.com/report/github.com/gogf/gf/v2)
|
||||
[](https://codecov.io/gh/gogf/gf)
|
||||
[](https://github.com/gogf/gf)
|
||||
[](https://github.com/gogf/gf)
|
||||
|
||||
[](https://github.com/gogf/gf/releases)
|
||||
[](https://github.com/gogf/gf/pulls)
|
||||
[](https://github.com/gogf/gf/pulls?q=is%3Apr+is%3Aclosed)
|
||||
[](https://github.com/gogf/gf/issues)
|
||||
[](https://github.com/gogf/gf/issues?q=is%3Aissue+is%3Aclosed)
|
||||

|
||||

|
||||
[](https://deepwiki.com/gogf/gf)
|
||||
|
||||
</div>
|
||||
|
||||
一款强大的框架,为了更快、更轻松、更高效的项目开发。
|
||||
|
||||
## 安装
|
||||
|
||||
```bash
|
||||
go get -u github.com/gogf/gf/v2
|
||||
```
|
||||
|
||||
## 文档
|
||||
|
||||
- 官方网站: [https://goframe.org](https://goframe.org)
|
||||
- 官方网站(en): [https://goframe.org/en](https://goframe.org/en)
|
||||
- 国内镜像: [https://goframe.org.cn](https://goframe.org.cn)
|
||||
- 镜像网站: [https://pages.goframe.org](https://pages.goframe.org)
|
||||
- 镜像网站: [离线文档](https://github.com/gogf/goframe.org-pdf?tab=readme-ov-file#%E6%9C%80%E6%96%B0%E7%89%88%E6%9C%AC)
|
||||
- Go包文档: [https://pkg.go.dev/github.com/gogf/gf/v2](https://pkg.go.dev/github.com/gogf/gf/v2)
|
||||
- 文档源码: [https://github.com/gogf/gf-site](https://github.com/gogf/gf-site)
|
||||
|
||||
## 贡献者
|
||||
|
||||
💖 [感谢所有使 GoFrame 成为可能的贡献者](https://github.com/gogf/gf/graphs/contributors) 💖
|
||||
|
||||
<a href="https://github.com/gogf/gf/graphs/contributors">
|
||||
<img src="https://goframe.org/img/contributors.svg?version=v2.10.2" alt="goframe contributors"/>
|
||||
</a>
|
||||
|
||||
## 许可证
|
||||
|
||||
`GoFrame` 采用 [MIT License](LICENSE) 许可,100%开源和免费。
|
||||
114
README_ZH.MD
114
README_ZH.MD
@ -1,114 +0,0 @@
|
||||
# GoFrame
|
||||
<img align="right" height="150px" src="https://goframe.org/cover.png">
|
||||
|
||||
[](https://godoc.org/github.com/gogf/gf)
|
||||
[](https://travis-ci.org/gogf/gf)
|
||||
[](https://goreportcard.com/report/github.com/gogf/gf)
|
||||
[](https://codecov.io/gh/gogf/gf/branch/master)
|
||||
[](https://github.com/gogf/gf)
|
||||
[](https://github.com/gogf/gf)
|
||||
|
||||
`GF(Go Frame)`是一款模块化、松耦合、生产级Go应用开发框架。提供了常用的核心开发组件,如:缓存、日志、文件、时间、队列、数组、集合、字符串、定时器、命令行、文件锁、内存锁、对象池、连接池、数据校验、数据编码、文件监控、定时任务、数据库ORM、TCP/UDP组件、进程管理/通信、
|
||||
并发安全容器等等。并提供了Web服务开发的系列核心组件,如:Router、Cookie、Session、服务注册、配置管理、模板引擎等等,支持热重启、热更新、多域名、多端口、多服务、HTTPS、Rewrite等特性。
|
||||
|
||||
|
||||
# 特点
|
||||
* 模块化、松耦合设计;
|
||||
* 丰富实用的开发模块;
|
||||
* 详尽的开发文档及示例;
|
||||
* 完善的本地中文化支持;
|
||||
* 致力于项目的通用方案;
|
||||
* 更适合企业及团队使用;
|
||||
* 更多请查阅文档及源码;
|
||||
|
||||
# 安装
|
||||
```html
|
||||
go get -u github.com/gogf/gf
|
||||
```
|
||||
或者
|
||||
`go.mod`:
|
||||
```
|
||||
require github.com/gogf/gf latest
|
||||
```
|
||||
> 如果您是从旧版本`1.x`升级到`1.5.0`那么请参考:[1.x升级到1.5.0](https://goframe.org/upgradeto150)
|
||||
|
||||
# 限制
|
||||
```shell
|
||||
golang版本 >= 1.9.2
|
||||
```
|
||||
|
||||
# 架构
|
||||
<div align=center>
|
||||
<img src="https://goframe.org/images/arch.png"/>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
# 文档
|
||||
|
||||
开发文档:[https://goframe.org](https://goframe.org)
|
||||
|
||||
接口文档:[https://godoc.org/github.com/gogf/gf](https://godoc.org/github.com/gogf/gf)
|
||||
|
||||
# 使用
|
||||
```go
|
||||
package main
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/g"
|
||||
"github.com/gogf/gf/g/net/ghttp"
|
||||
)
|
||||
|
||||
func main() {
|
||||
s := g.Server()
|
||||
s.BindHandler("/", func(r *ghttp.Request) {
|
||||
r.Response.Write("Hello World")
|
||||
})
|
||||
s.Run()
|
||||
}
|
||||
```
|
||||
|
||||
[更多..](https://goframe.org/start/index)
|
||||
|
||||
|
||||
# 协议
|
||||
|
||||
`GF` 使用非常友好的 [MIT](LICENSE) 开源协议进行发布,永久`100%`开源免费。
|
||||
|
||||
# 捐赠
|
||||
|
||||
捐赠支持`GF`框架的研发,
|
||||
请在捐赠时备注您的`github`/`gitee`账号名称。
|
||||
|
||||
<a href="https://goframe.org/images/donate.png" target="_blank">
|
||||
<img src="https://goframe.org/images/donate.png" width="300"/>
|
||||
</a>
|
||||
|
||||
# 贡献者
|
||||
|
||||
- [aloncn](https://github.com/aloncn)
|
||||
- [chenyang351](https://github.com/chenyang351)
|
||||
- [garfieldkwong](https://gitee.com/garfieldkwong)
|
||||
- [hailaz](https://gitee.com/hailaz)
|
||||
- [johng](https://gitee.com/johng)
|
||||
- [pibigstar](https://github.com/pibigstar)
|
||||
- [qq1054000800](https://gitee.com/qq1054000800)
|
||||
- [wenzi1](https://gitee.com/wenzi1)
|
||||
- [wxkj001](https://github.com/wxkj001)
|
||||
- [ymrjqyy](https://gitee.com/ymrjqyy)
|
||||
- [youyixiao](https://github.com/youyixiao)
|
||||
- [zhangjinfu](https://gitee.com/zhangjinfu)
|
||||
- [zhaopengme](https://github.com/zhaopengme)
|
||||
- [zseeker](https://gitee.com/zseeker)
|
||||
|
||||
# 捐赠者
|
||||
|
||||
- [flyke-xu](https://gitee.com/flyke-xu)
|
||||
- [hailaz](https://gitee.com/hailaz)
|
||||
- [mg91](https://gitee.com/mg91)
|
||||
- [pibigstar](https://github.com/pibigstar)
|
||||
- [tiangenglan](https://gitee.com/tiangenglan)
|
||||
- [wxkj](https://gitee.com/wxkj)
|
||||
- [zhuhuan12](https://gitee.com/zhuhuan12)
|
||||
- [zfan_codes](https://gitee.com/zfan_codes)
|
||||
|
||||
434
RELEASE.MD
434
RELEASE.MD
@ -1,434 +0,0 @@
|
||||
# `v1.6.0` (2019-04-09)
|
||||
|
||||
## 新功能/改进
|
||||
1. `gcron`定时任务模块增加运行日志记录功能:https://goframe.org/os/gcron/index
|
||||
1. `gredis`增加全局分组配置功能,并增加更多的配置选项`maxIdle/maxActive/idleTimeout/maxConnLifetime`:https://goframe.org/database/gredis/index
|
||||
1. `gcfg`模块增加更多的默认配置文件检索路径,并且增加全局分组配置特性,增加`Instance`单例方法:https://goframe.org/os/gcfg/index
|
||||
1. `gview`模块增加更多的默认配置文件检索路径,并且增加`Instance`单例方法:https://goframe.org/os/gview/index
|
||||
1. `ghttp`模块新功能及改进:
|
||||
- 新增`CORS`HTTP(S)跨域请求特性: https://goframe.org/net/ghttp/cors
|
||||
- 增加`TLSConfig`配置功能;
|
||||
- 去掉路由注册方法的`error`返回值,当产生注册错误时直接终端打印错误/输出到日志文件;
|
||||
- 增加在`HTTP Code 302`跳转时的`Set-Cookie`支持;
|
||||
- 增加对`SESSION ID`的安全性检查;
|
||||
- 增加对基于`HTTPS`的`WebSocket`支持(`WSS`):https://goframe.org/net/ghttp/websocket/index
|
||||
- `Request`对象增加`Error`方法,用于输出自定义错误信息到`WebServer`错误日志中;
|
||||
- 其他一些改进;
|
||||
1. `gdb`模块新功能及改进:
|
||||
- 新增`Instance`单例管理方法;
|
||||
- 新增`Structs/Scan`链式操作方法,`gdb.DB/TX`新增`GetStructs/GetScan`方法,用于结果集`struct`/`slice`映射转换:https://goframe.org/database/gdb/chaining
|
||||
- 新增`Safe`链式操作方法(默认非并发安全),用于链式安全控制:https://goframe.org/database/gdb/chaining
|
||||
- `Where`链式操作方法改进:
|
||||
- 方法支持任意的`string/map/slice/struct/*struct`类型;
|
||||
- 逻辑调整,当链式操作中存在多个`Where`方法调用时,自动转换为`And`条件;
|
||||
- 支持`slice`条件参数,常用在`SELECT IN`查询中,例如:`Where("uid IN(?)", g.Slice{1,2,3})`;
|
||||
- 支持在`map`类型条件参数的`key`中传递条件,例如:`Where(g.Map{"uid>?", uid})`;
|
||||
1. `gconv`及`gvalid`模块改进并去掉对私有`struct`方法属性的转换/校验;
|
||||
1. `gconv.Map`转换方法新增对`json tag`: `-`, `omitempty`的支持: https://goframe.org/util/gconv/map
|
||||
1. `gstr`模块新增 `ReplaceI/ReplaceIByArray/ReplaceIByMap`大小写非敏感替换方法;
|
||||
1. `gutil`模块增加`IsEmpty`方法,用于判断给定变量是否为空(整型0, 布尔false, slice/map长度为0, 其他为nil的情况,判断为空),并增加快捷方法`g.IsEmpty`;
|
||||
1. `gutil`模块增加`Export`方法,用于导出返回格式化打印的变量内容字符串,并增加快捷方法`g.Export`;
|
||||
1. `gspath`增加缓存及非缓存检索检索方法`Search`/`SearchWithCache`;
|
||||
1. `gjson`模块增加默认的`UseNumber`功能支持;
|
||||
1. `gmap`增加`SetIfNotExistFunc/SetIfNotExistFuncLock`方法;
|
||||
1. 迁移`greuseport`模块到新的仓库:https://github.com/gogf/greuseport
|
||||
1. 大量的单元测试完善;
|
||||
|
||||
## Bug Fix
|
||||
1. 修复`gqueue`模块的资源竞争问题;
|
||||
1. 修复`gconv.GTime`转换失败问题;
|
||||
1. 修复`gconv.String`在转换`int`参数时字节溢出问题;
|
||||
1. 修复`ghttp.Request`的`HTTP Basic Auth`校验问题;
|
||||
1. 修复`gxml`针对于非`UTF-8`编码内容转换的并发安全问题;
|
||||
1. 修复`gtime`部分`Format`(`G`&`j`)格式失效问题;
|
||||
1. 修复`gudp.Conn`对象的`RemoteAddr`获取客户端连接地址方法问题;
|
||||
1. 修复`gmap/gcache`模块的`GetOrSetFuncLock`方法,增加对回调方法返回值的`nil`判断,只有非nil返回值才会被保存;
|
||||
|
||||
|
||||
|
||||
# `v1.5.8` (2019-02-28)
|
||||
|
||||
## 新特性
|
||||
1. 主库从`gitee`迁移到了`github`( https://github.com/gogf/gf ),`gitee`作为镜像站,用于国内的代码贡献及ISSUE提交,迁移说明详见:https://goframe.org/upgradeto150
|
||||
1. 对常用的`container`数组模块: `garray`做了大量改进/完善工作,新增大量常用方法,并完善单元测试用例及方法注释,详见API文档:https://godoc.org/github.com/gogf/gf/g/container/garray
|
||||
1. 对常用的`container`集合模块: `gset`做了大量改进/完善工作,新增大量常用方法,并完善单元测试用例及方法注释,详见API文档:https://godoc.org/github.com/gogf/gf/g/container/gset
|
||||
1. 对常用的`container`MAP模块: `gmap`做了大量改进/完善工作,新增大量常用方法,并完善单元测试用例及方法注释,详见API文档:https://godoc.org/github.com/gogf/gf/g/container/gmap
|
||||
1. 对常用的字符串模块: `gstr`做了大量改进/完善工作,新增大量常用方法,并完善单元测试用例及方法注释,详见API文档:https://godoc.org/github.com/gogf/gf/g/text/gstr
|
||||
1. 改进`gform`中对`struct`/`*struct`参数的支持,`*Insert/*Save/*Replace/*Update/Where/Data`方法的参数调整为`interface{}`类型,并支持任意类型的: `string/map/slice/struct/*struct`参数传递,具体请参考:https://goframe.org/database/orm/chaining
|
||||
1. 新增/完善若干模块的单元测试用例, 包括:`gvalid`/`gregex`/`garray`/`gset`/`gmap`/`gstr`/`gconv`/`ghttp`/`gdb`;
|
||||
1. 由于`gkafka`模块比较重,且不是框架核心模块,因此将该模块迁移到新的仓库中独立管理,并去掉相关依赖包:https://github.com/gogf/gkafka
|
||||
1. 新增`greuseport`模块,用以实现TCP的`REUSEPORT`特性:https://godoc.org/github.com/gogf/gf/g/net/greuseport
|
||||
|
||||
## 新功能/改进
|
||||
1. 去掉模板引擎内置变量中自动初始化`session`对象带来的内存占用问题;
|
||||
1. `ghttp.Client`改进,增加若干方法,详见:https://goframe.org/net/ghttp/client
|
||||
1. `ghttp`分组路由增加`COMMON`方法,用以注册常用的`HTTP METHOD`(`GET/PUT/POST/DELETE`)路由;
|
||||
1. 更新框架依赖的`golang.org/x/sys`模块;
|
||||
1. 改进`gform`的批量操作(`Batch*`操作)返回结果对象,可以通过该结果对象获得批量操作准确的受影响记录行数;
|
||||
1. 将`gstr`/`gregex`模块从`util`分类迁移到了`text`分类目录下;
|
||||
1. 将`gtest`模块从`util`分类迁移到了`test`分类目录下;
|
||||
1. 完善`glog`方法注释;
|
||||
|
||||
## Bug Fix
|
||||
1. 修复带点的邮件格式,用`gvalid.Check`的"`email`"规则不能匹配成功;
|
||||
1. 修复`gvalid.Check`在`regex`规则下的检查失败问题;
|
||||
1. 修复`gcron`模块定时规则中天和周不允许`?`符号的问题;
|
||||
1. 修复`ghttp.Server`在部分异常情况下仍然返回`200`状态码的问题;
|
||||
1. 修复`gfpool`模块中由于原子操作问题造成的高并发"内存泄露"问题;
|
||||
1. 修复分组路由注册对象/控制时,方法`Index`的路由仅能通过`/xxx/index`访问的问题;
|
||||
1. 修复模板引擎使用中,当不存在`config.toml`(即使没使用)配置文件时的报错问题;
|
||||
1. 其他一些修复;
|
||||
|
||||
|
||||
|
||||
# `v1.4.6` (2019-01-24)
|
||||
|
||||
## 新特性
|
||||
1. 新增并发安全的高性能任务定时器模块`gtimer`, 类似于Java的`Timer`,但是比较于Java的`Timer`更加强大,内部实现采用灵活高效的`分层时间轮`设计,被设计为可管理维护百万级别以上数量的定时任务。`gtimer`为`GF`框架的核心模块之一,单元测试覆盖率达到`93.6%`:[https://goframe.org/os/gtimer/index](https://goframe.org/os/gtimer/index)
|
||||
1. 采用任务定时器`gtimer`重构`gcron`定时任务模块,去掉第三方`github.com/robfig/cron`包的使用。`gcron`增加单例模式的定时任务:[https://goframe.org/os/gcron/index#](https://goframe.org/os/gcron/index#);
|
||||
1. `gconv`类型转换模块支持对`struct`结构体中的**指针属性**转换:[https://goframe.org/util/gconv/struct](https://goframe.org/util/gconv/struct);
|
||||
1. `gform`增加对数据库类型的自动识别特性,这一特性在需要将查询结果`json`编码返回时非常有用: [https://goframe.org/database/orm/index](https://goframe.org/database/orm/index)
|
||||
1. `Travis CI`增加对`386`架构的自动化测试支持(目前已支持`386`和`amd64`);
|
||||
|
||||
## 新功能
|
||||
1. `ghttp`模块新增`Exit`、`ExitAll`、`ExitHook`方法,用于HTTP请求处理流程控制: [https://goframe.org/net/ghttp/service/object](https://goframe.org/net/ghttp/service/object);
|
||||
1. `grand`模块增加`Meet/MeetProb`方法,用于给定概率的随机满足判断,增加别名方法`N/Str/Digits/Letters`;
|
||||
1. `gvalid`数据/表单校验模块增加`16X`及`19X`手机号的校验支持;
|
||||
|
||||
## 功能改进
|
||||
1. `gform`设置默认的数据库连接池`CONN_MAX_LIFE`参数值为`30`秒;
|
||||
1. 改进`glist`模块,提高约`20%`左右性能,并增加若干链表操作方法;
|
||||
1. 改进`gqueue`模块,提高约`50`左右性能,并增加模块对`select`语法的支持(使用`Queue.C`): [https://goframe.org/container/gqueue/index](https://goframe.org/container/gqueue/index);
|
||||
1. 改进`gmlock`内存锁模块,并完善单元测试用例:[https://goframe.org/os/gmlock/index](https://goframe.org/os/gmlock/index);
|
||||
1. 改进并发安全容器所有的模块,调整并发安全控制非必需参数`safe...bool`为`unsafe...bool`;
|
||||
1. 改进`gpool`对象复用模块,支持并发安全;
|
||||
1. 更新`gkafka`模块的第三方依赖包;
|
||||
1. 完善`ghttp`模块的单元测试用例;
|
||||
|
||||
|
||||
## Bug Fix
|
||||
1. 修复`gmd5`模块操作文件时的文件指针未关闭问题;
|
||||
1. 修复`gcache`缓存项过期删除失效问题;
|
||||
1. 其他修复;
|
||||
|
||||
# `v1.3.8` (2018-12-26)
|
||||
|
||||
## 新特性
|
||||
1. 对`gform`完成重构,以提高扩展性,并修复部分细节问题、完善单元测试用例([https://goframe.org/database/orm/index](https://goframe.org/database/orm/index));
|
||||
1. `WebServer`路由注册新增分组路由特性([https://goframe.org/net/ghttp/group](https://goframe.org/net/ghttp/group));
|
||||
1. `WebServer`新增`Rewrite`路由重写特性([https://goframe.org/net/ghttp/static](https://goframe.org/net/ghttp/static));
|
||||
1. 增加框架运行时对开发环境的自动识别;
|
||||
1. 增加了`Travis CI`自动化构建/测试;
|
||||
|
||||
## 新功能
|
||||
1. 改进`WebServer`静态文件服务功能,增加`SetStaticPath`/`AddStaticPath`方法([https://goframe.org/net/ghttp/static](https://goframe.org/net/ghttp/static));
|
||||
1. `gform`新增`Filter`链式操作方法,用于过滤参数中的非表字段键值对([https://goframe.org/database/orm/linkop](https://goframe.org/database/orm/linkop));
|
||||
1. `gcache`新增`Data`方法,用以获取所有的缓存数据项;
|
||||
1. `gredis`增加`GetConn`方法获取原生redis连接对象;
|
||||
|
||||
## 功能改进
|
||||
1. 改进`gform`的`Where`方法,支持`slice`类型的参数,并更方便地支持`in`操作查询([https://goframe.org/database/orm/linkop](https://goframe.org/database/orm/linkop));
|
||||
1. 改进`gproc`进程间通信数据结构,将`pid`字段从`16bit`扩展为`24bit`;
|
||||
1. 改进`gconv`/`gmap`/`garray`,增加若干操作方法;
|
||||
1. 改进`gview`模板引擎中的`date`内置函数,当给定的时间戳为空时打印当前的系统时间;
|
||||
1. 改进`gview`模板引擎中,当打印的变量不存在时,显示为空(标准库默认显示为`<no value>`);
|
||||
1. 改进`WebServer`,去掉`HANGUP`的信号监听,避免程序通过`nohup`运行时产生异常退出问题;
|
||||
1. 改进`gcache`性能,并完善基准测试;
|
||||
|
||||
## Bug Fix
|
||||
1. 修复`gcache`在非LRU特性开启时的缓存关闭资源竞争问题,并修复`doSetWithLockCheck`内部方法的返回值问题;
|
||||
1. 修复`grand.intn`内部方法在`x86`架构下的随机数位溢出问题;
|
||||
1. 修复`gbinary`中`Int`方法针对`[]byte`参数长度自动匹配造成的字节长度溢出问题;
|
||||
1. 修复`gjson`由于官方标准库`json`不支持`map[interface{}]*`类型造成的Go变量编码问题;
|
||||
1. 修复`garray`中部分方法的数据竞争问题,修复二分查找排序问题;
|
||||
1. 修复`ghttp.Request.GetVar`方法获取参数问题;
|
||||
1. 修复`gform`的数据库连接池不起作用的问题;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
# `v1.2.11` (2018-11-26)
|
||||
## 新特性
|
||||
1. `ORM`新增对`SQLServer`及`Oracle`的支持([https://goframe.org/database/orm/database](https://goframe.org/database/orm/database));
|
||||
1. 完成`gvalid`模块校验结果的顺序特性([https://goframe.org/util/gvalid/checkmap](https://goframe.org/util/gvalid/checkmap));
|
||||
1. 改进`ghttp.Request.Exit`,使得调用该方法时立即退出业务执行,开发者无需调用`Exit`方法时再使用`return`返回([https://goframe.org/net/ghttp/service/object](https://goframe.org/net/ghttp/service/object));
|
||||
1. 模板引擎新增若干内置函数:`text/html/htmldecode/url/urldecode/date/compare/substr/strlimit/hidestr/highlight/toupper/tolower/nl2br` ([https://goframe.org/os/gview/funcs](https://goframe.org/os/gview/funcs));
|
||||
1. 模板引擎新增内置变量`Config` ([https://goframe.org/os/gview/vars](https://goframe.org/os/gview/vars));
|
||||
1. 改进`gconv.Struct`转换默认规则,支持不区分大小写的键名与属性名称匹配;
|
||||
1. `gform`配置文件支持`linkinfo`自定义数据库连接字段([https://goframe.org/database/orm/config](https://goframe.org/database/orm/config));
|
||||
1. `gfsnotify`模块增加对特定回调的取消注册功能([https://goframe.org/os/gfsnotify/index](https://goframe.org/os/gfsnotify/index));
|
||||
|
||||
|
||||
|
||||
## 新功能
|
||||
1. 改进`ghttp.Request`,增加`SetParam/GetParam`请求流程自定义变量设置/获取方法,用于在请求流程中的回调函数共享变量([https://goframe.org/net/ghttp/request](https://goframe.org/net/ghttp/request));
|
||||
1. 改进`ghttp.Response`,增加`ServeFileDownload`方法,用于WebServer引导客户端下载文件([https://goframe.org/net/ghttp/response](https://goframe.org/net/ghttp/response));
|
||||
1. `gvar`模块新增`gvar.VarRead`只读接口,用于控制对外只暴露数据读取功能;
|
||||
1. 增加`g.Throw`抛异常方法,`g.TryCatch`异常捕获方法封装;
|
||||
1. 改进`gcron`模块,增加自定义的Cron管理对象,增加`New/Start/Stop`方法;
|
||||
|
||||
|
||||
## 功能改进
|
||||
1. WebServer添加`RouterCacheExpire`配置参数,用于设置路由检索缓存过期时间;
|
||||
1. WebServer允许同一`HOOK`事件被多次绑定注册,先注册的回调函数优先级更高([https://goframe.org/net/ghttp/service/hook](https://goframe.org/net/ghttp/service/hook));
|
||||
1. 当前工作目录为系统临时目录时,`gcfg`/`gview`/`ghttp`模块默认不添加工作目录到搜索路径;
|
||||
1. 改进`WebSocket`默认支持跨域请求([https://goframe.org/net/ghttp/websocket](https://goframe.org/net/ghttp/websocket));
|
||||
1. 改进`gtime.Format`支持中文;
|
||||
1. 改进`gfsnotify`,支持编辑器对文件非执行标准编辑时(RENAME+CHMOD)的热更新问题;
|
||||
1. 改进`gtype.Set`方法,增加Set原子操作返回旧的变量值;
|
||||
1. `gfile.ScanDir`增加支持`pattern`多个文件模式匹配,使用'`,`'符号分隔多个匹配模式;
|
||||
1. `gcfg`模块增加获取配置变量为`*gvar.Var`;
|
||||
1. `gstr`模块增加对中文截取方法;
|
||||
1. 改进`gtime.StrToTime`对常用时间格式匹配模式,新增`gtime.ParseTimeFromContent`方法;
|
||||
1. 修改配置管理、模板引擎、调试模式的环境变量名称为大写下划线标准格式;
|
||||
1. 改进`grand`模块随机数生成设计,底层使用`crypto/rand`+缓冲区实现高速的随机数生成([https://goframe.org/util/grand/index](https://goframe.org/util/grand/index));
|
||||
|
||||
## 问题修复
|
||||
1. 修复`gspath`模块在`windows`下搜索失效问题;
|
||||
1. 修复`gspath`模块Search时带有indexFiles的检索问题;
|
||||
1. bug fix INZS1([https://github.com/gogf/gf/issues/INZS1](https://github.com/gogf/gf/issues/INZS1));
|
||||
1. 修复`gproc.ShellRun`在windows下的执行问题;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
# `v1.0.898 stable` (2018-10-24)
|
||||
|
||||
## 新特性
|
||||
1. `gf-orm`增加`sqlite`数据库类型支持([http://gf.johng.cn/database/orm/database](http://gf.johng.cn/database/orm/database));
|
||||
1. 增加`gkafka`模块,对kafka的客户端程序封装,支持分组消费及指定起始位置等特性,并提供简便易用的API接口([http://gf.johng.cn/database/gkafka/index](http://gf.johng.cn/database/gkafka/index));
|
||||
1. 增加go语言最新版本的`go modules`特性支持;
|
||||
1. 增加`gcron`定时任务模块([http://gf.johng.cn/os/gcron/index](http://gf.johng.cn/os/gcron/index));
|
||||
1. `Web Server`增加路由注册项获取/打印特性,所有的路由注册/回调注册一览无余;
|
||||
1. 模板引擎增加全局变量管理,并增加多个常用的内置函数及内置变量([http://gf.johng.cn/os/gview/funcs](http://gf.johng.cn/os/gview/funcs));
|
||||
1. `gredis`改进为单例操作方式(基于基层连接池特性),每次操作`redis`服务器时开发者无需显示调用`Close`方法执行关闭([http://gf.johng.cn/database/gredis/index](http://gf.johng.cn/database/gredis/index));
|
||||
1. `gf-orm`增加数据库操作自动`Close`特性(基于底层链接池特性),开发者无需再`defer db.Close()`,并增加`g.DB`数据库对象单例别名([http://gf.johng.cn/database/orm/linkop](http://gf.johng.cn/database/orm/linkop));
|
||||
1. 增加`gvar`通用动态变量模块([http://gf.johng.cn/container/gvar/index](http://gf.johng.cn/container/gvar/index));
|
||||
1. 数据结构容器增加`并发安全特性开启/关闭功能`,当关闭后和普通的数据结构无异,且在非并发安全模式下性能会得到提高;
|
||||
1. 新增`gmlock`内存锁模块([http://gf.johng.cn/os/gmlock/index](http://gf.johng.cn/os/gmlock/index));
|
||||
1. 增加`gaes`算法模块([http://gf.johng.cn/crypto/gaes/index](http://gf.johng.cn/crypto/gaes/index));
|
||||
1. `gproc`模块增加执行`shell`命令方法([http://gf.johng.cn/os/gproc/index](http://gf.johng.cn/os/gproc/index));
|
||||
1. 新增`gfcache`模块,用于带自动缓存更新的文件内容操作(文档待完善);
|
||||
|
||||
## 新功能
|
||||
1. `glog`增加链式操作方法,增加日志级别管理控制、分类管理、调试管理功能;
|
||||
1. `g.View`增加分组名称设置,支持通过`g.*`对象管理器获取多个命名的单例模板引擎对象;
|
||||
1. `glog`增加对文件名称格式的自定义设置,支持`gtime日期格式`;
|
||||
1. `gconv`增加`Ints/Uints/Floats/Interfaces`转换方法;
|
||||
1. `gjson`增加`Append`方法;
|
||||
1. `gparser`增加`NewUnsafe/Append`方法;
|
||||
1. `gcache`增加`GetOrSet/GetOrSetFunc/GetOrSetFuncLock`方法;
|
||||
1. `gset`增加`LockFunc/RLockFunc`方法;
|
||||
1. `ghttp.Response`方法完善,增加`ParseTpl/ParseTplContent/TplContent`方法,`Template`修改为`Tpl`方法;
|
||||
1. `ghttp.Request`增加获取用户真实IP判断;
|
||||
1. `Session`增加`Contains`方法;
|
||||
1. 完善`ghtml`模块,增加多个方法;
|
||||
1. `gcache`新增`Contains/SetIfNotExist`方法;
|
||||
1. `gvalid`增加`Error`对象,用以管理校验错误信息;
|
||||
1. `gvalid`模块增加`struct tag`的校验规则、自定义错误提示信息绑定的支持特性([http://gf.johng.cn/util/gvalid/index](http://gf.johng.cn/util/gvalid/index));
|
||||
1. `ghttp`增加输入参数与`struct`的`绑定机制`,并增加对应`params`标签支持([http://gf.johng.cn/net/ghttp/service/handler](http://gf.johng.cn/net/ghttp/service/handler));
|
||||
1. `ghttp.Request`增加服务端`BasicAuth`功能(文档待完善);
|
||||
1. `gvalid`增加字段校验别名,用于自定义返回结果字段,并更新WebServer中相关使用的模块;
|
||||
1. `gf-orm`链式操作增加`ForPage`方法,调整`Chunks`方法;
|
||||
1. `ghttp`对象路由注册增加`Init&Shut`自动回调方法,增加重复路由注册检测功能;
|
||||
1. `gfsnotify`增加默认递归`Add/Remove`特性;
|
||||
1. `ghttp.Response`增加`ServiceFile`方法;
|
||||
1. 其他一些新功能;
|
||||
|
||||
## 功能改进
|
||||
1. 改进`ghttp.Server`配置管理;
|
||||
1. 改进`gcache`底层对象继承关系,改进部分设计细节,提高性能;
|
||||
1. 改进`gfpool`文件指针池,修复部分错误,提升性能,并增加基准测试代码;
|
||||
1. 改进`gmap`系列并发安全map数据结构,增加多个易用性的方法;
|
||||
1. 改进`gconv.Struct`对象转换功能([http://gf.johng.cn/util/gconv/index](http://gf.johng.cn/util/gconv/index));
|
||||
1. 改进`grand`随机数生成规则,提供了极高的随机数生成性能,并保证每一次调用随机方法时生成的都是不同的随机数值([http://gf.johng.cn/util/grand/index](http://gf.johng.cn/util/grand/index));
|
||||
1. 改进`gfile`文件内容操作方法,增加若干常用的文件内容读取方法;
|
||||
1. 改进`gtime`模块,并增加时区转换方法;
|
||||
1. 改进`COOKIE`,去掉锁机制;
|
||||
1. 改进`SESSION`获取方法,新增多个类型获取方法;
|
||||
1. 改进`g.DB/g.Config`单例缓存键名;
|
||||
1. 改进`gtcp/gudp`超时错误判断机制;
|
||||
1. 改进`gtype`底层统一修改为原子操作;
|
||||
1. 改进`gvalid`对`struct`的`string`属性的默认值非必需校验;
|
||||
1. 改进`gvalid`在关联规则下的非必需校验;
|
||||
1. 改进`gf-orm`在调试模式下日志自动输出功能;
|
||||
1. `ghttp.Server/gspath`模块静态文件检索改进;
|
||||
1. 优化`ghttp.ServerConfig`配置,增加`struct/method``名称到uri`的转换规则,通过`SetNameToUri`方法进行灵活配置([http://gf.johng.cn/net/ghttp/service/object](http://gf.johng.cn/net/ghttp/service/object));
|
||||
1. 改进`*any/:name`路由匹配规则,支持不带名字的`*/:`路由规则;
|
||||
1. 修改默认配置文件名称 `config.yml` -> `config.toml`([http://gf.johng.cn/os/gcfg/index](http://gf.johng.cn/os/gcfg/index));
|
||||
1. 调整服务注册的`BindControllerMethod`及`BindObjectMethod`逻辑为绑定路由到指定的方法执行;
|
||||
1. 改进`garray`二分查找方法,增加安全操作处理;
|
||||
1. 改进`gdb.Result/Recorde` `ToXml`方法,增加可选的`rootTag`参数;
|
||||
1. 其他一些改进;
|
||||
|
||||
## 问题修复
|
||||
1. 修复`ghttp.Server`在`windows`下的重启失效问题;
|
||||
1. 修复`ghttp.Server`服务注册与回调注册路由重复判断问题;
|
||||
1. 修复`garray`排序数组`Add`变参时的死锁问题;
|
||||
1. 修复`gfsnotify`默认递归监控整个`gspath.Add`添加的目录的问题;
|
||||
1. 修复`ghttp.BindParams`对`@file`文件上传标识符的转义问题;
|
||||
1. 修复`ghttp.Server`日志路径丢失问题;
|
||||
1. 修复`多WebServer`下的状态检测问题;
|
||||
1. 修复`gvalid`模块`min/max`校验问题;
|
||||
1. 修复控制器和执行对象服务注册时绑定'/'路由的问题;
|
||||
1. 修复`gvalid.CheckStruct`自定义错误提示失效问题;
|
||||
1. `ghttp.Server`修复`hook`与`serve`方法的路由影响,并新增跳转方法;
|
||||
1. 其他一些修复;
|
||||
|
||||
## 其他改动
|
||||
1. 去掉`gfile.IsExecutable`方法;
|
||||
1. 目录调整,将`加密/解密`相关的包从`encoding`目录迁移到`crypto`目录下;
|
||||
1. 增加`gfsnotify/gfcache`调试信息;
|
||||
1. `gf-orm`允许写入的键值为`nil`时往数据库中写入`null`;
|
||||
1. 统一使用`gview.Params`类型作为模板变量类型;
|
||||
1. `gconv.MapToStruct`方法名称修改为`gconv.Struct`;
|
||||
1. `ghttp.Server`完善重启及停止的终端提示信息;
|
||||
1. 完善`gring`模块,增加`约瑟夫问题`代码作为`gring`示例程序;
|
||||
1. 其他一些改动;
|
||||
|
||||
|
||||
|
||||
# `v0.99.682 beta` (2018-08-07)
|
||||
## 新特性
|
||||
1、新增gdes包,用于DES加密/加密算法处理;
|
||||
2、新增gkafka包,kafka的golang客户端;
|
||||
3、新增gpool对象复用池,比较于标准库的sync.Pool更加灵活强大,可自定义对象的缓存时间、创建方法、销毁方法(http://gf.johng.cn/686654);
|
||||
4、完成网络通信gtcp/gudp包的重构,并进行了大量的改进工作,新增了详尽的开发文档及示例代码(http://gf.johng.cn/494382);
|
||||
5、增加gring并发安全环,标准库container/ring包的并发安全版本,并做了易用性的封装(http://gf.johng.cn/686655);
|
||||
6、gtime包新增了自定义日期格式话的支持,格式化语法类似PHP的date语法(http://gf.johng.cn/494387);
|
||||
7、gdb增加调试模式特性,使用SetDebug方法实现,在调试模式下可以获取详细的SQL执行记录,增加了详细的开发文档及示例代码(http://gf.johng.cn/702801);
|
||||
8、gdb增加查询缓存特性,使用Cache方法实现,增加了详细的开发文档及示例代码(http://gf.johng.cn/702801);
|
||||
9、ghttp.Server路由功能增加字段匹配规则特性,支持如:/order/list/{page}.html 动态路由规则特性(http://gf.johng.cn/702766);
|
||||
10、gpage分页包增加分页URL规则生成模板特性,内部可使用{.page}变量指定页码位置(http://gf.johng.cn/716438);
|
||||
11、增加gmap.Map对象,这是gmap.InterfaceInterfaceMap的别名;
|
||||
|
||||
## 新功能
|
||||
1、gdb增加MaxIdleConnCount/MaxOpenConnCount/MaxConnLifetime三项配置,并增加SetMaxConnLifetime方法;
|
||||
2、ghttp.Client增加HTTP账号密码设置功能(SetBasicAuth);
|
||||
3、glog新增对系统换行符号的自适配调整(\n|\r\n);
|
||||
4、增加glog控制台调试模式打印开关(SetDebug);
|
||||
5、gcfg增加SetFileName方法设置默认读取的配置文件名称;
|
||||
6、gcfg/gjson/gparser包新增Int8/16/32/64,Uint8/16/32/64方法;
|
||||
7、增加gzip方法的封装(Zip/Unzip);
|
||||
8、gview增加模板变量分隔符设置方法SetDelimiters;
|
||||
9、ghttp.Response增加Writef、Writefln方法;
|
||||
|
||||
## 功能改进
|
||||
1、改进gfilepool文件指针池设计;改进gfile文本内容写入,增加指针池使用
|
||||
2、gdb包增加调试模式特性,并支持在调试模式下获得已执行的SQL列表结果
|
||||
3、改进gproc进程间通信机制,增加进程消息分组特性,并限定队列大小
|
||||
4、gdb结果方法处理增加ToXml/ToJson方法
|
||||
5、gregx包名修改为gregex
|
||||
6、改进gtime.StrToTime方法,新增对常见标准时间日期的自动转换,以及对时区的自动识别支持,并调整gconv,gvalid对该包的引用
|
||||
7、增加对字符集转换的封装,gxml包中使用新增的字符集转换包来做处理
|
||||
8、ghttp.Server.EnableAdmin页面Restart接口支持GET参数newExeFilePath支持
|
||||
9、ghttp.Server平滑重启机制增加可自定义重启可执行文件路径,特别是针对windows系统特别有用(因为windows下不支持可执行文件覆盖更新)
|
||||
10、改进ghttp.Server静态文件检索设计,增加开发环境时的main包源码目录查找机制;改进gcfg/gview的main包源码目录查找机制
|
||||
11、优化gcache设计,LRU特性非默认开启;优化gtype/gcache基准测试脚本;新增gregx基准测试脚本,改进设计,提升性能
|
||||
12、gfile包增加GoRootOfBuild方法,用于获取编译时的GOROOT数值;并改进glog包中backtrace的GOROOT路径过滤处理;
|
||||
13、改进grpool代码质量,并改进对池化goroutine数量的限制设计
|
||||
14、改进gdb.Map/List及g.Map/List的类型定义,改用别名特性以便支持原生类型输入(map/slice),并修复gdb.Model.Update方法参数处理问题
|
||||
15、调整ghttp包示例代码目录结构,增加ghttp.Client自定义Header方法,ghttp.Cookie增加Map方法用于获得客户端提交的所有cookie值,构造成map返回
|
||||
16、删除gcharset中的getcharset方法
|
||||
17、去掉gmap中常用的基本数据类型转换获取方法
|
||||
18、改进gconv.String方法,当无法使用基本类型进行字符串转换时,使用json.Marshal进行转换
|
||||
19、gvalid.CheckObject方法名称修改为gvalid.CheckStruct
|
||||
|
||||
|
||||
## 问题修复
|
||||
1、修正gstr.IsNumeric错误
|
||||
2、修复当xml中encoding字符集为非UTF-8字符集时报错的问题
|
||||
3、修正gconv包float32->float64精度问题
|
||||
4、修复gpage包分页计数问题
|
||||
5、修复gdb批量数据Save错误
|
||||
6、去掉gpool中math.MAXINT64常量的使用,以修复int64到int类型的转换错误,兼容32位系统
|
||||
7、修正ghttp包没有使用Server仍然初始化相关异步goroutine的问题
|
||||
|
||||
|
||||
|
||||
|
||||
# `v0.98.503 beta` (2018-05-21)
|
||||
## 新特性
|
||||
1、平滑重启特性( http://gf.johng.cn/625833 );
|
||||
2、gflock文件锁模块( http://gf.johng.cn/626062 );
|
||||
3、gproc进程管理及通信模块( http://gf.johng.cn/626063 );
|
||||
4、gpage分页管理模块,强大的动态分页及静态分页功能,并为开发者自定义分页样式提供了极高的灵活度( http://gf.johng.cn/597431 );
|
||||
5、ghttp.Server增加多端口监听特性,并支持HTTP/HTTPS( http://gf.johng.cn/494366 , http://gf.johng.cn/598802 );
|
||||
6、增加gspath目录检索包管理工具,支持对多目录下的文件检索特性;
|
||||
7、ghttp包控制器及执行对象注册增加更灵活的动态路由特性,路由规则增加{method}变量支持;
|
||||
|
||||
## 新功能
|
||||
1、gutil包增加MapToStruct方法,支持将map数据类型映射为struct对象;
|
||||
2、gconv
|
||||
1)、gconv包增加按照类型名称字符串进行类型转换;
|
||||
2)、gconv包新增Time/TimeDuration类型转换方法;
|
||||
3、ghttp
|
||||
1)、增加Web Server目录安全访问控制机制;
|
||||
2)、ghttp.Server增加自定义状态码回调函数注册处理;
|
||||
4、gdb
|
||||
1)、gdb包增加gdb.GetStruct/gdb.Model.Struct方法,获取查询结果记录自动转换为指定对象;
|
||||
2)、gdb增加Value/Record/Result类型,增加对Value类型的系列类型转换方法;
|
||||
3)、gdb包增加db.GetCount,tx.GetCount,model.Count数量查询方法;
|
||||
|
||||
## 功能改进
|
||||
1、改进gredis客户端功能封装;
|
||||
2、改进grand包随机数生成性能;
|
||||
3、grand/gdb/gredis包增加benchmark性能测试脚本;
|
||||
4、改进gjson/gparser包的ToStruct方法实现;
|
||||
5、gdb :改进gdb.New获取ORM操作对象性能;
|
||||
6、gcfg :改进配置文件检索功能;
|
||||
7、gview:模板引擎增加多目录检索功能;
|
||||
8、gfile:增加源码main包目录获取方法MainPkgPath;
|
||||
9、ghttp
|
||||
1)、ghttp.Request增加请求进入和完成时间记录,并增加到默认日志内容中;
|
||||
2)、ghttp.Server事件回调之间支持通过ghttp.Request.Param自定义参数进行流程传参;
|
||||
10、gdb
|
||||
1)、改进gdb.Result与gdb.List, gdb.Record与gdb.Map之间的类型转换,便于业务层数据编码处理(如json/xml);
|
||||
2)、改进gdb.Tx.GetValue返回值类型;
|
||||
3)、gdb.Model.Data参数支持更加灵活的map参数;
|
||||
|
||||
## 问题修复
|
||||
1、ghttp
|
||||
1)、修复ghttp包路由缓存问题;
|
||||
2)、修复服务注册时的控制器及执行对象方法丢失问题;
|
||||
2、gconv
|
||||
1)、修正gconv.Float64方法位大小设置问题;
|
||||
2)、修复gconv.Int64(float64(xxx))问题;
|
||||
2、gdb
|
||||
1)、修复gdb.GetAll针对返回数据列表的for..range...的返回结果slice相同指针问题;
|
||||
2)、修复gdb.Delete方法错误;
|
||||
3)、修复gdb.Model.And/Or方法;
|
||||
4)、修复gdb.Model.Where方法参数处理问题;
|
||||
3、garray:修复garray包Remove方法锁机制问题;
|
||||
4、gtype :修复gtype.Float32/gtype.Float64对象类型的方法逻辑错误;
|
||||
5、gfsnotify:修复在windows下文件参数中不同文件分隔符引起的热更新机制失效问题;
|
||||
6、修复gvalid包验证问题:如果值为nil,并且不需要require*验证时,其他验证失效。并增加单元测试项,测试通过。
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
# `v0.97.399 beta` (2018-04-23)
|
||||
1、 增加gfsnotify文件监控模块;
|
||||
2、 配置管理模块增加配置文件自动检测更新机制;
|
||||
3、 模板引擎增加对模板文件的自动检测更新机制;
|
||||
4、 改进gconv包基本类型转换功能,提高转换性能;
|
||||
5、 增加gpage分页管理包,支持动态分页、静态分页以及自定义分页样式特性;
|
||||
6、 ghttp.Request增加Exit方法,用以标记服务退出,当在服务执行前调用后,服务将不再执行;
|
||||
7、 ghttp.Response去掉WriteString方法,统一使用Write方法返回数据流,是使用灵活的参数形式;
|
||||
8、 模板引擎增加模板变量暴露接口LockFunc/RLockFunc,以便支持开发者灵活处理模板变量;
|
||||
9、 ghttp.Server增加access & error log功能,并支持开发者自定义日志处理回调函数注册;
|
||||
10、增加gredis包,支持对redis的客户端操作封装,并将gredis.Redis对象加入到gins单例管理器中进行统一配置管理维护;
|
||||
11、gins单例管理器增加对单例对象配置文件的自动检测更新机制,当配置文件在外部发生变更时,自动刷新单例管理器中的单例对象;
|
||||
12、gdb数据库ORM包增加And/Or条件链式方法,并改进Where/Data方法参数灵活性;
|
||||
13、对于新增加的模块,同时也增加了对应的开发文档,并梳理完善了现有的其他模块开发文档;
|
||||
14、修复ISSUE:
|
||||
#IISWI github.com/gogf/gf/issues/IISWI,
|
||||
#IISMY github.com/gogf/gf/issues/IISMY,
|
||||
反馈并跟踪完成第三方依赖mxj包的ISSUE修复(github.com/clbanning/mxj/issues/48);
|
||||
|
||||
|
||||
|
||||
119
TODO.MD
119
TODO.MD
@ -1,119 +0,0 @@
|
||||
# ON THE WAY
|
||||
1. 增加图形验证码支持,至少支持数字和英文字母;
|
||||
1. Cookie&Session数据池化处理;
|
||||
1. ghttp.Client增加proxy特性;
|
||||
1. gtime增加对时区转换的封装,并简化失去转换时对类似+80500时区的支持;
|
||||
1. orm增加sqlite对Save方法的支持(去掉触发器语句);
|
||||
1. ghttp.Server增加Ip访问控制功能(DenyIps&AllowIps);
|
||||
1. ghttp增加返回数据压缩机制;
|
||||
1. gview中的template标签失效问题;
|
||||
1. ghttp.Server增加proxy功能特性,本地proxy和远程proxy,本地即将路由规则映射;远程即反向代理;
|
||||
1. gjson对大json数据的解析效率问题;
|
||||
1. ghttp增加route name特性,并同时支持backend和template(提供内置函数)引用,可以通过RedirectRoute方法给定route name和路由参数跳转到指定的路由地址上;
|
||||
1. gvalid校验支持当第一个规则失败后便不再校验后续的规则,最好做成链式操作;
|
||||
1. gvalid增加支持对[]rune的长度校验(一个中文占3个字节);
|
||||
1. ghttp.Request增加对输入参数的自动HtmlEncode机制;
|
||||
1. 常量命名风格根据golint进行修改;
|
||||
1. 开放rwmutex包,并将gjson的互斥锁使用自定义的mutex替换;
|
||||
1. 文档完善:
|
||||
- gconv struct tag、
|
||||
- 控制器及执行对象注册的Init&Shut方法、
|
||||
- ghttp.Response&ServeFile、gfcache、gproc shell执行、
|
||||
- ghttp Server&Client basic auth、
|
||||
- glog分类&日志等级&链式操作、gdb debug自动输出调试信息、gmlock内存锁、
|
||||
1. 服务注册域名增加对泛域名的支持;
|
||||
1. Cookie设置中文失效问题;
|
||||
1. 使用gconv将slice映射到struct属性上,例如redis hscan的结果集;
|
||||
1. 项目参考:
|
||||
- https://github.com/namreg/godown
|
||||
- https://github.com/Masterminds/sprig
|
||||
1. gform参考 https://gohouse.github.io/gorose/dist/index.html 进行改进
|
||||
1. gtcp提供简便的包发送/接收方法(SendPkg/RecvPkg)以解决常见的TCP通信粘包问题,并完善文档(参考:https://www.cnblogs.com/kex1n/p/6502002.html);
|
||||
1. 路由增加不区分大小写得匹配方式;
|
||||
1. 改进WebServer获取POST参数处理逻辑,当提交非form数据时,例如json数据,针对某些方法可以直接解析;
|
||||
1. WebServer增加可选择的路由覆盖配置,默认情况下不覆盖;
|
||||
1. grpool性能压测结果变慢的问题;
|
||||
1. 增加jumplist的数据结构容器;
|
||||
1. DelayQueue/PriorityQueue;
|
||||
1. 权限管理模块;
|
||||
1. 从ghttp中剥离SESSION功能构成单独的模块gsession;
|
||||
1. 改进gproc进程间通信处理逻辑,提高稳定性,以应对进程间大批量的数据发送/接收;
|
||||
1. ghttp的热重启的本地进程端口监听,在不使用该特性时默认关闭掉;
|
||||
1. gtcp增加对TLS加密通信的支持;
|
||||
1. 添加Save/Replace/BatchSave/BatchReplace方法对sqlite数据库的支持;
|
||||
1. 添加sqlite数据库的单元测试用例;
|
||||
1. gredis增加cluster支持;
|
||||
|
||||
# DONE
|
||||
1. gconv完善针对不同类型的判断,例如:尽量减少sprintf("%v", xxx)来执行string类型的转换;
|
||||
2. ghttp.Server请求执行中增加服务退出的方法,不再执行后续操作;
|
||||
3. ghttp.Response对象完善并改进数据返回方法(Write/WriteString);
|
||||
4. ghttp.Server请求执行中增加服务退出的方法,不再执行后续操作;
|
||||
5. 增加fsnotify包支持;
|
||||
6. 改进gcfg和gview的文件自动更新机制;
|
||||
7. 将模板变量进行暴露,以便应用端可以进行灵活控制;
|
||||
8. 跟踪第三方mxj包的issue问题:https://github.com/clbanning/mxj/issues/48;
|
||||
9. gdb Where方法参数的改进,研究是否可以将string参数类型修改为interface{};
|
||||
10. gpage分页控制功能;
|
||||
11. https支持;
|
||||
12. ghttp.Server日志中增加请求时间和返回时间,以便计算执行时间差;
|
||||
13. 由于去掉了gdb的单例模式,并且将gins的部分对象封装迁移到了g包中,需要同时梳理文档,完善修改;
|
||||
14. 在代码中增加https与http同时开启使用的示例代码,这块大家问得比较多;
|
||||
15. ghttp.Server多个事件之间通过ghttp.Request.Param自定义参数传参;
|
||||
16. 研究是否增加配置文件目录检索功能,特别是如何友好改进开发环境的配置文件默认目录问题;
|
||||
17. 增加ghttp.Server不同状态码的自定义处理方法;
|
||||
18. ghttp.Server平滑重启方案;
|
||||
19. 完善gconv类型转换功能,增加time.Time/time.Duration类型转换,并增加benchmark测试脚本
|
||||
20. 当二进制参数为nil时,gjson.LoadContent并将gjson.Json对象ToMap时会报错;
|
||||
21. 改进控制器及执行对象注册,更友好地支持动态路由注册,例如:注册规则为 /channel/:name,现有的控制器及执行对象注册很难友好支持这种动态形式;
|
||||
22. 当前gpage分页包的输出标签不支持li,大多数CSS框架都是li+a标签模式,需要提供可更加灵活的定制化功能实现;
|
||||
23. 平滑重启机制改进,以便于开发阶段调试;
|
||||
24. 对grpool进行优化改进,包括属性原子操作封装采用gtype实现,修正设计BUG:https://github.com/gogf/gf/issues/6;
|
||||
25. gredis增加redis密码支持;
|
||||
26. 改进ghttp.Server平滑重启机制,当新进程接管服务后,再使用进程间通信方式通知父进程销毁;
|
||||
27. gproc进程间通信增加分组特性,不同的进程间可以通过进程ID以及分组名称发送/获取进程消息;
|
||||
28. ORM增加获取被执行的sql语句的方法;
|
||||
29. gdb增加查询缓存特性;
|
||||
30. gpage分页增加对自定义后缀的支持,如:2.html, 2.php等等;
|
||||
31. gvalid包增加struct tag的校验规则、自定义错误提示信息绑定的支持特性;
|
||||
32. 增加文件缓存包,可根据fsnotify机制进行缓存更新;
|
||||
33. *any/:name路由匹配路由改进支持不带名字的*/:路由规则;
|
||||
34. ghttp静态文件服务改进(特别是403返回状态的修改);
|
||||
35. map转struct增加对tag的支持;
|
||||
36. gcache检查在i386下的int64->int转换问题;
|
||||
37. ghttp获取参数支持直接转struct功能;
|
||||
38. gfsnotify增加对于目录的监控;
|
||||
39. 检查windows下的平滑重启失效问题;
|
||||
40. ghttp.Server的Cookie及Session锁机制优化(去掉map锁机制);
|
||||
41. 解决glog串日志情况;
|
||||
42. glog增加对日志文件名称的生成规则设定,支持时间格式规则;
|
||||
43. ghttp日志增加客户端IP信息;
|
||||
44. 完善gform配置管理说明,g.DB/Database和gdb.New的区别;
|
||||
1. 完善配置管理章节,说明默认的配置文件更改方式;
|
||||
1. 服务注册时判断方法定义满足规范时才执行绑定,否则提示WARN信息;
|
||||
1. `gfsnotify`增加添加监听文件时的监听ID返回,以便调用端删除监听时只删除自己添加的监听,而不影响其他对该同一文件的监听回调;
|
||||
1. `gfsnotify`针对添加目录监听时无法使用多个`Watcher`,考虑改进,并考虑动态扩容全局`Watcher`方案;
|
||||
1. 由于系统对inotify实例数量(`fs.inotify.max_user_instances`)以及队列大小(`fs.inotify.max_user_watches`)有限制,需要改进`gfsnotify`;
|
||||
1. WebServer事件回调允许对同一个路由规则绑定多个事件回调;
|
||||
1. gcfg/gview/ghttp等模块加上对临时文件目录的自动添加监听判断(基本是开发环境下,特别是windows环境),去掉临时文件的监听,避免临时文件过大引起的运行缓慢占用内存问题;
|
||||
1. 改进gfpool在文件指针变化时的更新;
|
||||
1. ghttp hook回调使用方式在注册路由比较多的时候,优先级可能使得开发者混乱,考虑方式便于管理;
|
||||
1. gform对于MySQL字段类型为datetime类型的时区问题分析;
|
||||
1. 改进证书打开失败时的WebServer错误提示,前置HOOK校验后关闭后续的HOOK逻辑执行;
|
||||
1. 目前WebServer的HOOK是按照优先级执行的,需要增加覆盖特性;
|
||||
1. 更新跨域请求CORS相关功能文档;
|
||||
1. ghttp.Response增加输出内容后自动退出当前请求机制,不需要用户手动return,参考beego如何实现;
|
||||
1. gcfg包目前允许添加重复的目录路径,需要在SetPath/AddPath时判断重复性,不能添加重复的路径;
|
||||
1. gdb执行数据写入时,如果参数为struct/[]struct,自动映射与表字段对应关系,不再使用gconv标签标识;
|
||||
1. gdb的Data方法支持struct参数传入;
|
||||
1. gfcache依旧使用gcache作为缓存控制对象,不要使用gmap;
|
||||
1. 增加对ghttp路由注册的{.struct}/{.method}单元测试;
|
||||
1. gconv针对struct的转换增加json tag支持,gconv.Map默认也支持json tag, 完善开发文档;
|
||||
1. 增加SO_REUSEPORT的支持;
|
||||
1. gkafka这个包比较重,未来从框架中剥离出来;
|
||||
1. str_ireplace: http://php.net/manual/en/function.str-ireplace.php
|
||||
1. strpos/stripos/strrpos/strripos: http://php.net/manual/en/function.stripos.php
|
||||
1. gfile对于文件的读写强行使用了gfpool,在某些场景下不合适,需要考虑剥离开,并为开发者提供单独的指针池文件操作特性;
|
||||
1. ghttp.Client自动Close机制;
|
||||
1. ghttp路由功能增加分组路由特性;
|
||||
1. 增加可选择性的orm tag特性,用以数据表记录与struct对象转换的键名属性映射;
|
||||
21
cmd/gf/LICENSE
Normal file
21
cmd/gf/LICENSE
Normal file
@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2018 john@goframe.org https://goframe.org
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
33
cmd/gf/Makefile
Normal file
33
cmd/gf/Makefile
Normal file
@ -0,0 +1,33 @@
|
||||
.DEFAULT_GOAL := pack
|
||||
|
||||
pack: pack.template-single pack.template-mono pack.template-mono-app
|
||||
|
||||
pack.template-single:
|
||||
@rm -fr temp
|
||||
@mkdir temp || exit 0
|
||||
@cd temp && git clone https://github.com/gogf/template-single
|
||||
@rm -fr temp/template-single/.git
|
||||
@cd temp && gf pack template-single ../internal/packed/template-single.go -n=packed -y
|
||||
@rm -fr temp
|
||||
|
||||
pack.template-mono:
|
||||
@rm -fr temp
|
||||
@mkdir temp || exit 0
|
||||
@cd temp && git clone https://github.com/gogf/template-mono
|
||||
@rm -fr temp/template-mono/.git
|
||||
@cd temp && gf pack template-mono ../internal/packed/template-mono.go -n=packed -y
|
||||
@rm -fr temp
|
||||
|
||||
pack.template-mono-app:
|
||||
@rm -fr temp
|
||||
@mkdir temp || exit 0
|
||||
@cd temp && git clone https://github.com/gogf/template-single
|
||||
@cd temp && mv template-single template-mono-app
|
||||
@rm -fr temp/template-mono-app/.git
|
||||
@rm -fr temp/template-mono-app/.gitattributes
|
||||
@rm -fr temp/template-mono-app/.gitignore
|
||||
@rm -fr temp/template-mono-app/go.mod
|
||||
@rm -fr temp/template-mono-app/go.sum
|
||||
@grep -irl 'template-single' temp| xargs perl -pi -e 's/template-single/template-mono-app/g'
|
||||
@cd temp && gf pack template-mono-app ../internal/packed/template-mono-app.go -n=packed -y
|
||||
@rm -fr temp
|
||||
82
cmd/gf/README.MD
Normal file
82
cmd/gf/README.MD
Normal file
@ -0,0 +1,82 @@
|
||||
English | [简体中文](README.zh_CN.MD)
|
||||
|
||||
# gf
|
||||
|
||||
`gf` is a powerful CLI tool for building [GoFrame](https://goframe.org) application with convenience.
|
||||
|
||||
## 1. Install
|
||||
|
||||
## 1) PreCompiled Binary
|
||||
|
||||
You can also install `gf` tool using pre-built binaries: <https://github.com/gogf/gf/releases>
|
||||
|
||||
1. `Mac` & `Linux`
|
||||
|
||||
```shell
|
||||
wget -O gf https://github.com/gogf/gf/releases/latest/download/gf_$(go env GOOS)_$(go env GOARCH) && chmod +x gf && ./gf install -y && rm ./gf
|
||||
```
|
||||
|
||||
> If you're using `zsh`, you might need rename your alias by command `alias gf=gf` to resolve the conflicts between `gf` and `git fetch`.
|
||||
|
||||
2. `Windows`
|
||||
Manually download, execute in command line it and then follow the instruction.
|
||||
|
||||
3. Database support
|
||||
|
||||
| DB | builtin support | remarks |
|
||||
| :--------: | :-------------: | :-------------------------------------------------------------------------------------------------------------------------------------------------------------: |
|
||||
| mysql | yes | - |
|
||||
| mariadb | yes | - |
|
||||
| tidb | yes | - |
|
||||
| mssql | yes | - |
|
||||
| oracle | yes | - |
|
||||
| pgsql | yes | - |
|
||||
| sqlite | yes | - |
|
||||
| sqlitecgo | no | to support sqlite database on 32bit architecture systems, manually add package import to the [source codes](./internal/cmd/cmd_gen_dao.go) and do the building. |
|
||||
| clickhouse | yes | - |
|
||||
| dm | no | manually add package import to the [source codes](./internal/cmd/cmd_gen_dao.go) and do the building. |
|
||||
|
||||
## 2) Manually Install
|
||||
|
||||
```shell
|
||||
go install github.com/gogf/gf/cmd/gf/v2@latest # latest version
|
||||
go install github.com/gogf/gf/cmd/gf/v2@v2.5.5 # certain version(should be >= v2.5.5)
|
||||
```
|
||||
|
||||
## 2. Commands
|
||||
|
||||
```shell
|
||||
$ gf -h
|
||||
USAGE
|
||||
gf COMMAND [OPTION]
|
||||
|
||||
COMMAND
|
||||
up upgrade GoFrame version/tool to latest one in current project
|
||||
env show current Golang environment variables
|
||||
fix auto fixing codes after upgrading to new GoFrame version
|
||||
run running go codes with hot-compiled-like feature
|
||||
gen automatically generate go files for dao/do/entity/pb/pbentity
|
||||
tpl template parsing and building commands
|
||||
init create and initialize an empty GoFrame project
|
||||
pack packing any file/directory to a resource file, or a go file
|
||||
build cross-building go project for lots of platforms
|
||||
docker build docker image for current GoFrame project
|
||||
install install gf binary to system (might need root/admin permission)
|
||||
version show version information of current binary
|
||||
doc download https://pages.goframe.org/ to run locally
|
||||
|
||||
OPTION
|
||||
-y, --yes all yes for all command without prompt ask
|
||||
-v, --version show version information of current binary
|
||||
-d, --debug show internal detailed debugging information
|
||||
-h, --help more information about this command
|
||||
|
||||
ADDITIONAL
|
||||
Use "gf COMMAND -h" for details about a command.
|
||||
```
|
||||
|
||||
## 3. FAQ
|
||||
|
||||
### 1). Command `gf run` returns `pipe: too many open files`
|
||||
|
||||
Please use `ulimit -n 65535` to enlarge your system configuration for max open files for current terminal shell session, and then `gf run`.
|
||||
82
cmd/gf/README.zh_CN.MD
Normal file
82
cmd/gf/README.zh_CN.MD
Normal file
@ -0,0 +1,82 @@
|
||||
[English](README.MD) | 简体中文
|
||||
|
||||
# gf
|
||||
|
||||
`gf` 是一个强大的 CLI 工具,用于便捷地构建 [GoFrame](https://goframe.org) 应用程序。
|
||||
|
||||
## 1. 安装
|
||||
|
||||
## 1) 预编译二进制文件
|
||||
|
||||
您也可以使用预构建的二进制文件安装 `gf` 工具:<https://github.com/gogf/gf/releases>
|
||||
|
||||
1. `Mac` & `Linux`
|
||||
|
||||
```shell
|
||||
wget -O gf https://github.com/gogf/gf/releases/latest/download/gf_$(go env GOOS)_$(go env GOARCH) && chmod +x gf && ./gf install -y && rm ./gf
|
||||
```
|
||||
|
||||
> 如果您使用 `zsh`,您可能需要通过命令 `alias gf=gf` 重命名别名以解决 `gf` 和 `git fetch` 之间的冲突。
|
||||
|
||||
2. `Windows`
|
||||
手动下载,在命令行中执行,然后按照说明操作。
|
||||
|
||||
3. 数据库支持
|
||||
|
||||
| 数据库 | 内置支持 | 说明 |
|
||||
| :--------: | :-------------: | :-------------------------------------------------------------------------------------------------------------------------------------------------------------: |
|
||||
| mysql | 是 | - |
|
||||
| mariadb | 是 | - |
|
||||
| tidb | 是 | - |
|
||||
| mssql | 是 | - |
|
||||
| oracle | 是 | - |
|
||||
| pgsql | 是 | - |
|
||||
| sqlite | 是 | - |
|
||||
| sqlitecgo | 否 | 要在 32 位架构系统上支持 sqlite 数据库,请手动向[源代码](./internal/cmd/cmd_gen_dao.go)添加包导入并进行构建。 |
|
||||
| clickhouse | 是 | - |
|
||||
| dm | 否 | 手动向[源代码](./internal/cmd/cmd_gen_dao.go)添加包导入并进行构建。 |
|
||||
|
||||
## 2) 手动安装
|
||||
|
||||
```shell
|
||||
go install github.com/gogf/gf/cmd/gf/v2@latest # 最新版本
|
||||
go install github.com/gogf/gf/cmd/gf/v2@v2.5.5 # 特定版本(应该 >= v2.5.5)
|
||||
```
|
||||
|
||||
## 2. 命令
|
||||
|
||||
```shell
|
||||
$ gf -h
|
||||
用法
|
||||
gf 命令 [选项]
|
||||
|
||||
命令
|
||||
up 升级项目中的 GoFrame 版本/工具到最新版本
|
||||
env 显示当前 Golang 环境变量
|
||||
fix 升级到新 GoFrame 版本后自动修复代码
|
||||
run 运行 go 代码,具有热编译功能
|
||||
gen 自动生成 dao/do/entity/pb/pbentity 的 go 文件
|
||||
tpl 模板解析和构建命令
|
||||
init 创建并初始化一个空的 GoFrame 项目
|
||||
pack 将任何文件/目录打包到资源文件或 go 文件
|
||||
build 为多个平台交叉编译 go 项目
|
||||
docker 为当前 GoFrame 项目构建 docker 镜像
|
||||
install 将 gf 二进制文件安装到系统(可能需要 root/admin 权限)
|
||||
version 显示当前二进制文件的版本信息
|
||||
doc 下载 https://pages.goframe.org/ 本地运行
|
||||
|
||||
选项
|
||||
-y, --yes 对所有命令都使用 yes,不再提示
|
||||
-v, --version 显示当前二进制文件的版本信息
|
||||
-d, --debug 显示内部详细的调试信息
|
||||
-h, --help 显示此命令的更多信息
|
||||
|
||||
附加信息
|
||||
使用 "gf 命令 -h" 获取有关命令的详细信息。
|
||||
```
|
||||
|
||||
## 3. 常见问题
|
||||
|
||||
### 1). 命令 `gf run` 返回 `pipe: too many open files`
|
||||
|
||||
请使用 `ulimit -n 65535` 扩大系统配置以增加当前终端 shell 会话的最大打开文件数,然后再运行 `gf run`。
|
||||
119
cmd/gf/gfcmd/gfcmd.go
Normal file
119
cmd/gf/gfcmd/gfcmd.go
Normal file
@ -0,0 +1,119 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
// Package gfcmd provides the management of CLI commands for `gf` tool.
|
||||
package gfcmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"runtime"
|
||||
|
||||
_ "github.com/gogf/gf/cmd/gf/v2/internal/packed"
|
||||
|
||||
"github.com/gogf/gf/v2/errors/gcode"
|
||||
"github.com/gogf/gf/v2/errors/gerror"
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gcfg"
|
||||
"github.com/gogf/gf/v2/os/gcmd"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/text/gstr"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/cmd"
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/allyes"
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
const cliFolderName = `hack`
|
||||
|
||||
// Command manages the CLI command of `gf`.
|
||||
// This struct can be globally accessible and extended with custom struct.
|
||||
type Command struct {
|
||||
*gcmd.Command
|
||||
}
|
||||
|
||||
// Run starts running the command according the command line arguments and options.
|
||||
func (c *Command) Run(ctx context.Context) {
|
||||
defer func() {
|
||||
if exception := recover(); exception != nil {
|
||||
if err, ok := exception.(error); ok {
|
||||
mlog.Print(err.Error())
|
||||
} else {
|
||||
panic(gerror.NewCodef(gcode.CodeInternalPanic, "%+v", exception))
|
||||
}
|
||||
}
|
||||
}()
|
||||
|
||||
// CLI configuration, using the `hack/config.yaml` in priority.
|
||||
if path, _ := gfile.Search(cliFolderName); path != "" {
|
||||
if adapter, ok := g.Cfg().GetAdapter().(*gcfg.AdapterFile); ok {
|
||||
if err := adapter.SetPath(path); err != nil {
|
||||
mlog.Fatal(err)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// zsh alias "git fetch" conflicts checks.
|
||||
handleZshAlias()
|
||||
|
||||
// -y option checks.
|
||||
allyes.Init()
|
||||
|
||||
// just run.
|
||||
if err := c.RunWithError(ctx); err != nil {
|
||||
// Exit with error message and exit code 1.
|
||||
// It is very important to exit the command process with code 1.
|
||||
mlog.Fatalf(`%+v`, err)
|
||||
}
|
||||
}
|
||||
|
||||
// GetCommand retrieves and returns the root command of CLI `gf`.
|
||||
func GetCommand(ctx context.Context) (*Command, error) {
|
||||
root, err := gcmd.NewFromObject(cmd.GF)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
err = root.AddObject(
|
||||
cmd.Up,
|
||||
cmd.Env,
|
||||
cmd.Fix,
|
||||
cmd.Run,
|
||||
cmd.Gen,
|
||||
cmd.Tpl,
|
||||
cmd.Init,
|
||||
cmd.Pack,
|
||||
cmd.Build,
|
||||
cmd.Docker,
|
||||
cmd.Install,
|
||||
cmd.Version,
|
||||
cmd.Doc,
|
||||
)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
command := &Command{
|
||||
root,
|
||||
}
|
||||
return command, nil
|
||||
}
|
||||
|
||||
// zsh alias "git fetch" conflicts checks.
|
||||
func handleZshAlias() {
|
||||
if runtime.GOOS == "windows" {
|
||||
return
|
||||
}
|
||||
if home, err := gfile.Home(); err == nil {
|
||||
zshPath := gfile.Join(home, ".zshrc")
|
||||
if gfile.Exists(zshPath) {
|
||||
var (
|
||||
aliasCommand = `alias gf=gf`
|
||||
content = gfile.GetContents(zshPath)
|
||||
)
|
||||
if !gstr.Contains(content, aliasCommand) {
|
||||
_ = gfile.PutContentsAppend(zshPath, "\n"+aliasCommand+"\n")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
72
cmd/gf/go.mod
Normal file
72
cmd/gf/go.mod
Normal file
@ -0,0 +1,72 @@
|
||||
module github.com/gogf/gf/cmd/gf/v2
|
||||
|
||||
go 1.23.0
|
||||
|
||||
require (
|
||||
github.com/gogf/gf/contrib/drivers/clickhouse/v2 v2.10.2
|
||||
github.com/gogf/gf/contrib/drivers/dm/v2 v2.10.2
|
||||
github.com/gogf/gf/contrib/drivers/mssql/v2 v2.10.2
|
||||
github.com/gogf/gf/contrib/drivers/mysql/v2 v2.10.2
|
||||
github.com/gogf/gf/contrib/drivers/oracle/v2 v2.10.2
|
||||
github.com/gogf/gf/contrib/drivers/pgsql/v2 v2.10.2
|
||||
github.com/gogf/gf/contrib/drivers/sqlite/v2 v2.10.2
|
||||
github.com/gogf/gf/v2 v2.10.2
|
||||
github.com/gogf/selfupdate v0.0.0-20231215043001-5c48c528462f
|
||||
github.com/olekukonko/tablewriter v1.1.0
|
||||
github.com/schollz/progressbar/v3 v3.15.0
|
||||
golang.org/x/mod v0.25.0
|
||||
golang.org/x/tools v0.26.0
|
||||
)
|
||||
|
||||
require (
|
||||
aead.dev/minisign v0.2.0 // indirect
|
||||
gitee.com/chunanyong/dm v1.8.12 // indirect
|
||||
github.com/BurntSushi/toml v1.5.0 // indirect
|
||||
github.com/ClickHouse/clickhouse-go/v2 v2.0.15 // indirect
|
||||
github.com/clbanning/mxj/v2 v2.7.0 // indirect
|
||||
github.com/dustin/go-humanize v1.0.1 // indirect
|
||||
github.com/emirpasic/gods/v2 v2.0.0-alpha // indirect
|
||||
github.com/fatih/color v1.18.0 // indirect
|
||||
github.com/fsnotify/fsnotify v1.9.0 // indirect
|
||||
github.com/glebarez/go-sqlite v1.21.2 // indirect
|
||||
github.com/go-logr/logr v1.4.3 // indirect
|
||||
github.com/go-logr/stdr v1.2.2 // indirect
|
||||
github.com/go-sql-driver/mysql v1.7.1 // indirect
|
||||
github.com/golang-sql/civil v0.0.0-20220223132316-b832511892a9 // indirect
|
||||
github.com/golang-sql/sqlexp v0.1.0 // indirect
|
||||
github.com/golang/snappy v0.0.1 // indirect
|
||||
github.com/google/uuid v1.6.0 // indirect
|
||||
github.com/gorilla/websocket v1.5.3 // indirect
|
||||
github.com/grokify/html-strip-tags-go v0.1.0 // indirect
|
||||
github.com/lib/pq v1.10.9 // indirect
|
||||
github.com/magiconair/properties v1.8.10 // indirect
|
||||
github.com/mattn/go-colorable v0.1.13 // indirect
|
||||
github.com/mattn/go-isatty v0.0.20 // indirect
|
||||
github.com/mattn/go-runewidth v0.0.16 // indirect
|
||||
github.com/microsoft/go-mssqldb v1.7.1 // indirect
|
||||
github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db // indirect
|
||||
github.com/olekukonko/errors v1.1.0 // indirect
|
||||
github.com/olekukonko/ll v0.0.9 // indirect
|
||||
github.com/paulmach/orb v0.7.1 // indirect
|
||||
github.com/pierrec/lz4/v4 v4.1.14 // indirect
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec // indirect
|
||||
github.com/rivo/uniseg v0.4.7 // indirect
|
||||
github.com/shopspring/decimal v1.3.1 // indirect
|
||||
github.com/sijms/go-ora/v2 v2.7.10 // indirect
|
||||
go.opentelemetry.io/auto/sdk v1.1.0 // indirect
|
||||
go.opentelemetry.io/otel v1.38.0 // indirect
|
||||
go.opentelemetry.io/otel/metric v1.38.0 // indirect
|
||||
go.opentelemetry.io/otel/sdk v1.38.0 // indirect
|
||||
go.opentelemetry.io/otel/trace v1.38.0 // indirect
|
||||
golang.org/x/crypto v0.38.0 // indirect
|
||||
golang.org/x/net v0.40.0 // indirect
|
||||
golang.org/x/sync v0.14.0 // indirect
|
||||
golang.org/x/sys v0.35.0 // indirect
|
||||
golang.org/x/term v0.32.0 // indirect
|
||||
golang.org/x/text v0.25.0 // indirect
|
||||
gopkg.in/yaml.v3 v3.0.1 // indirect
|
||||
modernc.org/libc v1.22.5 // indirect
|
||||
modernc.org/mathutil v1.5.0 // indirect
|
||||
modernc.org/memory v1.5.0 // indirect
|
||||
modernc.org/sqlite v1.23.1 // indirect
|
||||
)
|
||||
253
cmd/gf/go.sum
Normal file
253
cmd/gf/go.sum
Normal file
@ -0,0 +1,253 @@
|
||||
aead.dev/minisign v0.2.0 h1:kAWrq/hBRu4AARY6AlciO83xhNnW9UaC8YipS2uhLPk=
|
||||
aead.dev/minisign v0.2.0/go.mod h1:zdq6LdSd9TbuSxchxwhpA9zEb9YXcVGoE8JakuiGaIQ=
|
||||
gitee.com/chunanyong/dm v1.8.12 h1:WupbFZL0MRNIIiCPaLDHgFi5jkdkjzjPReuWPaInGwk=
|
||||
gitee.com/chunanyong/dm v1.8.12/go.mod h1:EPRJnuPFgbyOFgJ0TRYCTGzhq+ZT4wdyaj/GW/LLcNg=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.1 h1:lGlwhPtrX6EVml1hO0ivjkUxsSyl4dsiw9qcA1k/3IQ=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.1/go.mod h1:RKUqNu35KJYcVG/fqTRqmuXJZYNhYkBrnC/hX7yGbTA=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.5.1 h1:sO0/P7g68FrryJzljemN+6GTssUXdANk6aJ7T1ZxnsQ=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.5.1/go.mod h1:h8hyGFDsU5HMivxiS2iYFZsgDbU9OnnJ163x5UGVKYo=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.1 h1:6oNBlSdi1QqM1PNW7FPA6xOGA5UNsXnkaYZz9vdPGhA=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.1/go.mod h1:s4kgfzA0covAXNicZHDMN58jExvcng2mC/DepXiF1EI=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/security/keyvault/azkeys v1.0.1 h1:MyVTgWR8qd/Jw1Le0NZebGBUCLbtak3bJ3z1OlqZBpw=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/security/keyvault/azkeys v1.0.1/go.mod h1:GpPjLhVR9dnUoJMyHWSPy71xY9/lcmpzIPZXmF0FCVY=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/security/keyvault/internal v1.0.0 h1:D3occbWoio4EBLkbkevetNMAVX197GkzbUMtqjGWn80=
|
||||
github.com/Azure/azure-sdk-for-go/sdk/security/keyvault/internal v1.0.0/go.mod h1:bTSOgj05NGRuHHhQwAdPnYr9TOdNmKlZTgGLL6nyAdI=
|
||||
github.com/AzureAD/microsoft-authentication-library-for-go v1.2.1 h1:DzHpqpoJVaCgOUdVHxE8QB52S6NiVdDQvGlny1qvPqA=
|
||||
github.com/AzureAD/microsoft-authentication-library-for-go v1.2.1/go.mod h1:wP83P5OoQ5p6ip3ScPr0BAq0BvuPAvacpEuSzyouqAI=
|
||||
github.com/BurntSushi/toml v1.5.0 h1:W5quZX/G/csjUnuI8SUYlsHs9M38FC7znL0lIO+DvMg=
|
||||
github.com/BurntSushi/toml v1.5.0/go.mod h1:ukJfTF/6rtPPRCnwkur4qwRxa8vTRFBF0uk2lLoLwho=
|
||||
github.com/ClickHouse/clickhouse-go v1.5.4/go.mod h1:EaI/sW7Azgz9UATzd5ZdZHRUhHgv5+JMS9NSr2smCJI=
|
||||
github.com/ClickHouse/clickhouse-go/v2 v2.0.15 h1:lLAZliqrZEygkxosLaW1qHyeTb4Ho7fVCZ0WKCpLocU=
|
||||
github.com/ClickHouse/clickhouse-go/v2 v2.0.15/go.mod h1:Z21o82zD8FFqefOQDg93c0XITlxGbTsWQuRm588Azkk=
|
||||
github.com/StackExchange/wmi v0.0.0-20190523213315-cbe66965904d/go.mod h1:3eOhrUMpNV+6aFIbp5/iudMxNCF27Vw2OZgy4xEx0Fg=
|
||||
github.com/bkaradzic/go-lz4 v1.0.0/go.mod h1:0YdlkowM3VswSROI7qDxhRvJ3sLhlFrRRwjwegp5jy4=
|
||||
github.com/clbanning/mxj/v2 v2.7.0 h1:WA/La7UGCanFe5NpHF0Q3DNtnCsVoxbPKuyBNHWRyME=
|
||||
github.com/clbanning/mxj/v2 v2.7.0/go.mod h1:hNiWqW14h+kc+MdF9C6/YoRfjEJoR3ou6tn/Qo+ve2s=
|
||||
github.com/cloudflare/golz4 v0.0.0-20150217214814-ef862a3cdc58/go.mod h1:EOBUe0h4xcZ5GoxqC5SDxFQ8gwyZPKQoEzownBlhI80=
|
||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY=
|
||||
github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto=
|
||||
github.com/emirpasic/gods/v2 v2.0.0-alpha h1:dwFlh8pBg1VMOXWGipNMRt8v96dKAIvBehtCt6OtunU=
|
||||
github.com/emirpasic/gods/v2 v2.0.0-alpha/go.mod h1:W0y4M2dtBB9U5z3YlghmpuUhiaZT2h6yoeE+C1sCp6A=
|
||||
github.com/fatih/color v1.18.0 h1:S8gINlzdQ840/4pfAwic/ZE0djQEH3wM94VfqLTZcOM=
|
||||
github.com/fatih/color v1.18.0/go.mod h1:4FelSpRwEGDpQ12mAdzqdOukCy4u8WUtOY6lkT/6HfU=
|
||||
github.com/fsnotify/fsnotify v1.9.0 h1:2Ml+OJNzbYCTzsxtv8vKSFD9PbJjmhYF14k/jKC7S9k=
|
||||
github.com/fsnotify/fsnotify v1.9.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0=
|
||||
github.com/glebarez/go-sqlite v1.21.2 h1:3a6LFC4sKahUunAmynQKLZceZCOzUthkRkEAl9gAXWo=
|
||||
github.com/glebarez/go-sqlite v1.21.2/go.mod h1:sfxdZyhQjTM2Wry3gVYWaW072Ri1WMdWJi0k6+3382k=
|
||||
github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
|
||||
github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
|
||||
github.com/go-logr/logr v1.4.3 h1:CjnDlHq8ikf6E492q6eKboGOC0T8CDaOvkHCIg8idEI=
|
||||
github.com/go-logr/logr v1.4.3/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY=
|
||||
github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag=
|
||||
github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE=
|
||||
github.com/go-ole/go-ole v1.2.4/go.mod h1:XCwSNxSkXRo4vlyPy93sltvi/qJq0jqQhjqQNIwKuxM=
|
||||
github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0=
|
||||
github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w=
|
||||
github.com/go-sql-driver/mysql v1.7.1 h1:lUIinVbN1DY0xBg0eMOzmmtGoHwWBbvnWubQUrtU8EI=
|
||||
github.com/go-sql-driver/mysql v1.7.1/go.mod h1:OXbVy3sEdcQ2Doequ6Z5BW6fXNQTmx+9S1MCJN5yJMI=
|
||||
github.com/gogf/gf/contrib/drivers/clickhouse/v2 v2.10.2 h1:K9MuyxpkwbQFRypXZnqZm06l0N2p3urM8PEqH45IYXo=
|
||||
github.com/gogf/gf/contrib/drivers/clickhouse/v2 v2.10.2/go.mod h1:Pr/klQ7g0l0qx/MtnFqu9sgeMfVul8ntj/kvGuopJcM=
|
||||
github.com/gogf/gf/contrib/drivers/dm/v2 v2.10.2 h1:jgppTDbSMW/zMRrhvmYFvvArfHQyy556dujwjFRdtUw=
|
||||
github.com/gogf/gf/contrib/drivers/dm/v2 v2.10.2/go.mod h1:FsEjU9SLF4ZSuN8YVkMzCxmFFjEBTbzvXw7D9SzK6IU=
|
||||
github.com/gogf/gf/contrib/drivers/mssql/v2 v2.10.2 h1:7V+23ohcOWvT4Fgf/79uEs51VLfESbhgntkdLL9IPyA=
|
||||
github.com/gogf/gf/contrib/drivers/mssql/v2 v2.10.2/go.mod h1:8mQd1INT1l7c8gYnUdfqlbDdTyq9ZqjkdvlLFdPD6RE=
|
||||
github.com/gogf/gf/contrib/drivers/mysql/v2 v2.10.2 h1:UdUV+7GhwYLpkwz7VrwIVO/1ZYodyzSL5is25NET24A=
|
||||
github.com/gogf/gf/contrib/drivers/mysql/v2 v2.10.2/go.mod h1:eKc+0i3Il7efS2BBjmpy7T9wvN9NGRd67ZV94r9behA=
|
||||
github.com/gogf/gf/contrib/drivers/oracle/v2 v2.10.2 h1:1ufTnX0yqYvfY0h8cMTfcwKnmkfPl/ClJNsbHEboJhc=
|
||||
github.com/gogf/gf/contrib/drivers/oracle/v2 v2.10.2/go.mod h1:gHYoaDSZA2DeZ7e/n6YcplP3fXAjDvijDFz0WijHASU=
|
||||
github.com/gogf/gf/contrib/drivers/pgsql/v2 v2.10.2 h1:u8EpP24GkprogROnJ7htMov9Fc66pTP1eVYrWxiCYOs=
|
||||
github.com/gogf/gf/contrib/drivers/pgsql/v2 v2.10.2/go.mod h1:GmvM3r8GVByVMi4RD2+MCs5+CfxVXPMeT8mVDkAaAXE=
|
||||
github.com/gogf/gf/contrib/drivers/sqlite/v2 v2.10.2 h1:KLS68SWS2W749x7e+eCCOO3UD2Sbw+bIbLEPR8o1FXw=
|
||||
github.com/gogf/gf/contrib/drivers/sqlite/v2 v2.10.2/go.mod h1:uLcsu73PfpyhRc0Jq0gGAWQjN1tyGU9iBRrYgt/lu7g=
|
||||
github.com/gogf/gf/v2 v2.10.2 h1:46IO0Uc8e85/FqdftJFskfDejJLBL0JBnGS5qOftUu8=
|
||||
github.com/gogf/gf/v2 v2.10.2/go.mod h1:Svl1N+E8G/QshU2DUbh/3J/AJauqCgUnxHurXWR4Qx0=
|
||||
github.com/gogf/selfupdate v0.0.0-20231215043001-5c48c528462f h1:7xfXR/BhG3JDqO1s45n65Oyx9t4E/UqDOXep6jXdLCM=
|
||||
github.com/gogf/selfupdate v0.0.0-20231215043001-5c48c528462f/go.mod h1:HnYoio6S7VaFJdryKcD/r9HgX+4QzYfr00XiXUo/xz0=
|
||||
github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
|
||||
github.com/golang-jwt/jwt/v5 v5.2.0 h1:d/ix8ftRUorsN+5eMIlF4T6J8CAt9rch3My2winC1Jw=
|
||||
github.com/golang-jwt/jwt/v5 v5.2.0/go.mod h1:pqrtFR0X4osieyHYxtmOUWsAWrfe1Q5UVIyoH402zdk=
|
||||
github.com/golang-sql/civil v0.0.0-20220223132316-b832511892a9 h1:au07oEsX2xN0ktxqI+Sida1w446QrXBRJ0nee3SNZlA=
|
||||
github.com/golang-sql/civil v0.0.0-20220223132316-b832511892a9/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0=
|
||||
github.com/golang-sql/sqlexp v0.1.0 h1:ZCD6MBpcuOVfGVqsEmY5/4FtYiKz6tSyUv9LPEDei6A=
|
||||
github.com/golang-sql/sqlexp v0.1.0/go.mod h1:J4ad9Vo8ZCWQ2GMrC4UCQy1JpCbwU9m3EOqtpKwwwHI=
|
||||
github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk=
|
||||
github.com/golang/snappy v0.0.1 h1:Qgr9rKW7uDUkrbSmQeiDsGa8SjGyCOGtuasMWwvp2P4=
|
||||
github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q=
|
||||
github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
|
||||
github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE=
|
||||
github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8=
|
||||
github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU=
|
||||
github.com/google/pprof v0.0.0-20221118152302-e6195bd50e26 h1:Xim43kblpZXfIBQsbuBVKCudVG457BR2GZFIz3uw3hQ=
|
||||
github.com/google/pprof v0.0.0-20221118152302-e6195bd50e26/go.mod h1:dDKJzRmX4S37WGHujM7tX//fmj1uioxKzKxz3lo4HJo=
|
||||
github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0=
|
||||
github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/gorilla/handlers v1.4.2/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ=
|
||||
github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE=
|
||||
github.com/gorilla/websocket v1.5.3 h1:saDtZ6Pbx/0u+bgYQ3q96pZgCzfhKXGPqt7kZ72aNNg=
|
||||
github.com/gorilla/websocket v1.5.3/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE=
|
||||
github.com/grokify/html-strip-tags-go v0.1.0 h1:03UrQLjAny8xci+R+qjCce/MYnpNXCtgzltlQbOBae4=
|
||||
github.com/grokify/html-strip-tags-go v0.1.0/go.mod h1:ZdzgfHEzAfz9X6Xe5eBLVblWIxXfYSQ40S/VKrAOGpc=
|
||||
github.com/jmoiron/sqlx v1.2.0/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks=
|
||||
github.com/k0kubun/go-ansi v0.0.0-20180517002512-3bf9e2903213/go.mod h1:vNUNkEQ1e29fT/6vq2aBdFsgNPmy8qMdSay1npru+Sw=
|
||||
github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8=
|
||||
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
|
||||
github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE=
|
||||
github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk=
|
||||
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
|
||||
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
|
||||
github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc=
|
||||
github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw=
|
||||
github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
|
||||
github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw=
|
||||
github.com/lib/pq v1.10.9/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o=
|
||||
github.com/magiconair/properties v1.8.10 h1:s31yESBquKXCV9a/ScB3ESkOjUYYv+X0rg8SYxI99mE=
|
||||
github.com/magiconair/properties v1.8.10/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0=
|
||||
github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA=
|
||||
github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg=
|
||||
github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM=
|
||||
github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY=
|
||||
github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y=
|
||||
github.com/mattn/go-runewidth v0.0.16 h1:E5ScNMtiwvlvB5paMFdw9p4kSQzbXFikJ5SQO6TULQc=
|
||||
github.com/mattn/go-runewidth v0.0.16/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w=
|
||||
github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc=
|
||||
github.com/microsoft/go-mssqldb v1.7.1 h1:KU/g8aWeM3Hx7IMOFpiwYiUkU+9zeISb4+tx3ScVfsM=
|
||||
github.com/microsoft/go-mssqldb v1.7.1/go.mod h1:kOvZKUdrhhFQmxLZqbwUV0rHkNkZpthMITIb2Ko1IoA=
|
||||
github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db h1:62I3jR2EmQ4l5rM/4FEfDWcRD+abF5XlKShorW5LRoQ=
|
||||
github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db/go.mod h1:l0dey0ia/Uv7NcFFVbCLtqEBQbrT4OCwCSKTEv6enCw=
|
||||
github.com/mkevac/debugcharts v0.0.0-20191222103121-ae1c48aa8615/go.mod h1:Ad7oeElCZqA1Ufj0U9/liOF4BtVepxRcTvr2ey7zTvM=
|
||||
github.com/olekukonko/errors v1.1.0 h1:RNuGIh15QdDenh+hNvKrJkmxxjV4hcS50Db478Ou5sM=
|
||||
github.com/olekukonko/errors v1.1.0/go.mod h1:ppzxA5jBKcO1vIpCXQ9ZqgDh8iwODz6OXIGKU8r5m4Y=
|
||||
github.com/olekukonko/ll v0.0.9 h1:Y+1YqDfVkqMWuEQMclsF9HUR5+a82+dxJuL1HHSRpxI=
|
||||
github.com/olekukonko/ll v0.0.9/go.mod h1:En+sEW0JNETl26+K8eZ6/W4UQ7CYSrrgg/EdIYT2H8g=
|
||||
github.com/olekukonko/tablewriter v1.1.0 h1:N0LHrshF4T39KvI96fn6GT8HEjXRXYNDrDjKFDB7RIY=
|
||||
github.com/olekukonko/tablewriter v1.1.0/go.mod h1:5c+EBPeSqvXnLLgkm9isDdzR3wjfBkHR9Nhfp3NWrzo=
|
||||
github.com/paulmach/orb v0.7.1 h1:Zha++Z5OX/l168sqHK3k4z18LDvr+YAO/VjK0ReQ9rU=
|
||||
github.com/paulmach/orb v0.7.1/go.mod h1:FWRlTgl88VI1RBx/MkrwWDRhQ96ctqMCh8boXhmqB/A=
|
||||
github.com/paulmach/protoscan v0.2.1/go.mod h1:SpcSwydNLrxUGSDvXvO0P7g7AuhJ7lcKfDlhJCDw2gY=
|
||||
github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY=
|
||||
github.com/pierrec/lz4/v4 v4.1.14 h1:+fL8AQEZtz/ijeNnpduH0bROTu0O3NZAlPjQxGn8LwE=
|
||||
github.com/pierrec/lz4/v4 v4.1.14/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4=
|
||||
github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c h1:+mdjkGKdHQG3305AYmdv1U2eRNDiU2ErMBj1gwrq8eQ=
|
||||
github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c/go.mod h1:7rwL4CYBLnjLxUqIJNnCWiEdr3bn6IUYi15bNlnbCCU=
|
||||
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo=
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec h1:W09IVJc94icq4NjY3clb7Lk8O1qJ8BdBEF8z0ibU0rE=
|
||||
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo=
|
||||
github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
|
||||
github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ=
|
||||
github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
|
||||
github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR38lUII=
|
||||
github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o=
|
||||
github.com/schollz/progressbar/v3 v3.15.0 h1:cNZmcNiVyea6oofBTg80ZhVXxf3wG/JoAhqCCwopkQo=
|
||||
github.com/schollz/progressbar/v3 v3.15.0/go.mod h1:ncBdc++eweU0dQoeZJ3loXoAc+bjaallHRIm8pVVeQM=
|
||||
github.com/shirou/gopsutil v2.19.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA=
|
||||
github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA=
|
||||
github.com/shirou/w32 v0.0.0-20160930032740-bb4de0191aa4/go.mod h1:qsXQc7+bwAM3Q1u/4XEfrquwF8Lw7D7y5cD8CuHnfIc=
|
||||
github.com/shopspring/decimal v1.3.1 h1:2Usl1nmF/WZucqkFZhnfFYxxxu8LG21F6nPQBE5gKV8=
|
||||
github.com/shopspring/decimal v1.3.1/go.mod h1:DKyhrW/HYNuLGql+MJL6WCR6knT2jwCFRcu2hWCYk4o=
|
||||
github.com/sijms/go-ora/v2 v2.7.10 h1:GSLdj0PYYgSndhsnm7b6p32OqgnwnUZSkFb3j+htfhI=
|
||||
github.com/sijms/go-ora/v2 v2.7.10/go.mod h1:EHxlY6x7y9HAsdfumurRfTd+v8NrEOTR3Xl4FWlH6xk=
|
||||
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
|
||||
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
||||
github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals=
|
||||
github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U=
|
||||
github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U=
|
||||
github.com/tklauser/go-sysconf v0.3.10/go.mod h1:C8XykCvCb+Gn0oNCWPIlcb0RuglQTYaQ2hGm7jmxEFk=
|
||||
github.com/tklauser/numcpus v0.4.0/go.mod h1:1+UI3pD8NW14VMwdgJNJ1ESk2UnwhAnz5hMwiKKqXCQ=
|
||||
github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0=
|
||||
go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA=
|
||||
go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A=
|
||||
go.opentelemetry.io/otel v1.7.0/go.mod h1:5BdUoMIz5WEs0vt0CUEMtSSaTSHBBVwrhnz7+nrD5xk=
|
||||
go.opentelemetry.io/otel v1.38.0 h1:RkfdswUDRimDg0m2Az18RKOsnI8UDzppJAtj01/Ymk8=
|
||||
go.opentelemetry.io/otel v1.38.0/go.mod h1:zcmtmQ1+YmQM9wrNsTGV/q/uyusom3P8RxwExxkZhjM=
|
||||
go.opentelemetry.io/otel/metric v1.38.0 h1:Kl6lzIYGAh5M159u9NgiRkmoMKjvbsKtYRwgfrA6WpA=
|
||||
go.opentelemetry.io/otel/metric v1.38.0/go.mod h1:kB5n/QoRM8YwmUahxvI3bO34eVtQf2i4utNVLr9gEmI=
|
||||
go.opentelemetry.io/otel/sdk v1.38.0 h1:l48sr5YbNf2hpCUj/FoGhW9yDkl+Ma+LrVl8qaM5b+E=
|
||||
go.opentelemetry.io/otel/sdk v1.38.0/go.mod h1:ghmNdGlVemJI3+ZB5iDEuk4bWA3GkTpW+DOoZMYBVVg=
|
||||
go.opentelemetry.io/otel/sdk/metric v1.38.0 h1:aSH66iL0aZqo//xXzQLYozmWrXxyFkBJ6qT5wthqPoM=
|
||||
go.opentelemetry.io/otel/sdk/metric v1.38.0/go.mod h1:dg9PBnW9XdQ1Hd6ZnRz689CbtrUp0wMMs9iPcgT9EZA=
|
||||
go.opentelemetry.io/otel/trace v1.7.0/go.mod h1:fzLSB9nqR2eXzxPXb2JW9IKE+ScyXA48yyE4TNvoHqU=
|
||||
go.opentelemetry.io/otel/trace v1.38.0 h1:Fxk5bKrDZJUH+AMyyIXGcFAPah0oRcT+LuNtJrmcNLE=
|
||||
go.opentelemetry.io/otel/trace v1.38.0/go.mod h1:j1P9ivuFsTceSWe1oY+EeW3sc+Pp42sO++GHkg4wwhs=
|
||||
go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto=
|
||||
go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
|
||||
golang.org/x/crypto v0.38.0 h1:jt+WWG8IZlBnVbomuhg2Mdq0+BBQaHbtqHEFEigjUV8=
|
||||
golang.org/x/crypto v0.38.0/go.mod h1:MvrbAqul58NNYPKnOra203SB9vpuZW0e+RRZV+Ggqjw=
|
||||
golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
|
||||
golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
|
||||
golang.org/x/mod v0.25.0 h1:n7a+ZbQKQA/Ysbyb0/6IbB1H/X41mKgbhfv7AfG/44w=
|
||||
golang.org/x/mod v0.25.0/go.mod h1:IXM97Txy2VM4PJ3gI61r1YEk/gAj6zAHN3AdZt6S9Ww=
|
||||
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
|
||||
golang.org/x/net v0.40.0 h1:79Xs7wF06Gbdcg4kdCCIQArK11Z1hr5POQ6+fIYHNuY=
|
||||
golang.org/x/net v0.40.0/go.mod h1:y0hY0exeL2Pku80/zKK7tpntoX23cqL3Oa6njdgRtds=
|
||||
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.14.0 h1:woo0S4Yywslg6hp4eUFjTVOyKt0RookbpAHG4c1HmhQ=
|
||||
golang.org/x/sync v0.14.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191220220014-0732a990476f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210228012217-479acdf4ea46/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220429233432-b5fbb4746d32/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
|
||||
golang.org/x/sys v0.35.0 h1:vz1N37gP5bs89s7He8XuIYXpyY0+QlsKmzipCbUtyxI=
|
||||
golang.org/x/sys v0.35.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k=
|
||||
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
|
||||
golang.org/x/term v0.24.0/go.mod h1:lOBK/LVxemqiMij05LGJ0tzNr8xlmwBRJ81PX6wVLH8=
|
||||
golang.org/x/term v0.32.0 h1:DR4lr0TjUs3epypdhTOkMmuF5CDFJ/8pOnbzMZPQ7bg=
|
||||
golang.org/x/term v0.32.0/go.mod h1:uZG1FhGx848Sqfsq4/DlJr3xGGsYMu/L5GW4abiaEPQ=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
|
||||
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.25.0 h1:qVyWApTSYLk/drJRO5mDlNYskwQznZmkpV2c8q9zls4=
|
||||
golang.org/x/text v0.25.0/go.mod h1:WEdwpYrmk1qmdHvhkSTNPm3app7v4rsT8F2UD6+VHIA=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE=
|
||||
golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA=
|
||||
golang.org/x/tools v0.26.0 h1:v/60pFQmzmT9ExmjDv2gGIfi3OqfKoEP6I5+umXlbnQ=
|
||||
golang.org/x/tools v0.26.0/go.mod h1:TPVVj70c7JJ3WCazhD8OdXcZg/og+b9+tH/KxylGwH0=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw=
|
||||
google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
|
||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
|
||||
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
|
||||
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
|
||||
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
|
||||
modernc.org/libc v1.22.5 h1:91BNch/e5B0uPbJFgqbxXuOnxBQjlS//icfQEGmvyjE=
|
||||
modernc.org/libc v1.22.5/go.mod h1:jj+Z7dTNX8fBScMVNRAYZ/jF91K8fdT2hYMThc3YjBY=
|
||||
modernc.org/mathutil v1.5.0 h1:rV0Ko/6SfM+8G+yKiyI830l3Wuz1zRutdslNoQ0kfiQ=
|
||||
modernc.org/mathutil v1.5.0/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E=
|
||||
modernc.org/memory v1.5.0 h1:N+/8c5rE6EqugZwHii4IFsaJ7MUhoWX07J5tC/iI5Ds=
|
||||
modernc.org/memory v1.5.0/go.mod h1:PkUhL0Mugw21sHPeskwZW4D6VscE/GQJOnIpCnW6pSU=
|
||||
modernc.org/sqlite v1.23.1 h1:nrSBg4aRQQwq59JpvGEQ15tNxoO5pX/kUjcRNwSAGQM=
|
||||
modernc.org/sqlite v1.23.1/go.mod h1:OrDj17Mggn6MhE+iPbBNf7RGKODDE9NFT0f3EwDzJqk=
|
||||
22
cmd/gf/go.work
Normal file
22
cmd/gf/go.work
Normal file
@ -0,0 +1,22 @@
|
||||
go 1.23.0
|
||||
|
||||
use ./
|
||||
|
||||
// =====================================================================================================
|
||||
// NOTE:
|
||||
// Please update associated commands in ../../.set_version.sh if any of the follows replacements change.
|
||||
// =====================================================================================================
|
||||
|
||||
replace (
|
||||
github.com/gogf/gf/contrib/drivers/clickhouse/v2 => ../../contrib/drivers/clickhouse
|
||||
github.com/gogf/gf/contrib/drivers/mssql/v2 => ../../contrib/drivers/mssql
|
||||
github.com/gogf/gf/contrib/drivers/mysql/v2 => ../../contrib/drivers/mysql
|
||||
github.com/gogf/gf/contrib/drivers/oracle/v2 => ../../contrib/drivers/oracle
|
||||
github.com/gogf/gf/contrib/drivers/pgsql/v2 => ../../contrib/drivers/pgsql
|
||||
github.com/gogf/gf/contrib/drivers/sqlite/v2 => ../../contrib/drivers/sqlite
|
||||
github.com/gogf/gf/contrib/drivers/mariadb/v2 => ../../contrib/drivers/mariadb
|
||||
github.com/gogf/gf/contrib/drivers/tidb/v2 => ../../contrib/drivers/tidb
|
||||
github.com/gogf/gf/contrib/drivers/oceanbase/v2 => ../../contrib/drivers/oceanbase
|
||||
github.com/gogf/gf/contrib/drivers/gaussdb/v2 => ../../contrib/drivers/gaussdb
|
||||
github.com/gogf/gf/v2 => ../../
|
||||
)
|
||||
79
cmd/gf/internal/cmd/cmd.go
Normal file
79
cmd/gf/internal/cmd/cmd.go
Normal file
@ -0,0 +1,79 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
// Package cmd provides the management of CLI commands for `gf` tool.
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"strings"
|
||||
|
||||
"github.com/gogf/gf/v2"
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gcmd"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/service"
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
// GF is the management object for `gf` command line tool.
|
||||
var GF = cGF{}
|
||||
|
||||
type cGF struct {
|
||||
g.Meta `name:"gf" ad:"{cGFAd}"`
|
||||
}
|
||||
|
||||
const (
|
||||
cGFAd = `
|
||||
ADDITIONAL
|
||||
Use "gf COMMAND -h" for details about a command.
|
||||
`
|
||||
)
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cGFAd`: cGFAd,
|
||||
})
|
||||
}
|
||||
|
||||
type cGFInput struct {
|
||||
g.Meta `name:"gf"`
|
||||
Yes bool `short:"y" name:"yes" brief:"all yes for all command without prompt ask" orphan:"true"`
|
||||
Version bool `short:"v" name:"version" brief:"show version information of current binary" orphan:"true"`
|
||||
Debug bool `short:"d" name:"debug" brief:"show internal detailed debugging information" orphan:"true"`
|
||||
}
|
||||
|
||||
type cGFOutput struct{}
|
||||
|
||||
func (c cGF) Index(ctx context.Context, in cGFInput) (out *cGFOutput, err error) {
|
||||
// Version.
|
||||
if in.Version {
|
||||
_, err = Version.Index(ctx, cVersionInput{})
|
||||
return
|
||||
}
|
||||
|
||||
answer := "n"
|
||||
// No argument or option, do installation checks.
|
||||
if data, isInstalled := service.Install.IsInstalled(); !isInstalled {
|
||||
mlog.Print("hi, it seems it's the first time you installing gf cli.")
|
||||
answer = gcmd.Scanf("do you want to install gf(%s) binary to your system? [y/n]: ", gf.VERSION)
|
||||
} else if !data.IsSelf {
|
||||
mlog.Print("hi, you have installed gf cli.")
|
||||
answer = gcmd.Scanf("do you want to install gf(%s) binary to your system? [y/n]: ", gf.VERSION)
|
||||
}
|
||||
if strings.EqualFold(answer, "y") {
|
||||
if err = service.Install.Run(ctx); err != nil {
|
||||
return
|
||||
}
|
||||
gcmd.Scan("press `Enter` to exit...")
|
||||
return
|
||||
}
|
||||
|
||||
// Print help content.
|
||||
gcmd.CommandFromCtx(ctx).Print()
|
||||
return
|
||||
}
|
||||
399
cmd/gf/internal/cmd/cmd_build.go
Normal file
399
cmd/gf/internal/cmd/cmd_build.go
Normal file
@ -0,0 +1,399 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"os"
|
||||
"regexp"
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
"github.com/gogf/gf/v2/encoding/gbase64"
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gbuild"
|
||||
"github.com/gogf/gf/v2/os/gcmd"
|
||||
"github.com/gogf/gf/v2/os/genv"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/os/gproc"
|
||||
"github.com/gogf/gf/v2/os/gtime"
|
||||
"github.com/gogf/gf/v2/text/gregex"
|
||||
"github.com/gogf/gf/v2/text/gstr"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
var Build = cBuild{
|
||||
nodeNameInConfigFile: "gfcli.build",
|
||||
packedGoFileName: "internal/packed/build_pack_data.go",
|
||||
}
|
||||
|
||||
type cBuild struct {
|
||||
g.Meta `name:"build" brief:"{cBuildBrief}" dc:"{cBuildDc}" eg:"{cBuildEg}" ad:"{cBuildAd}"`
|
||||
nodeNameInConfigFile string // nodeNameInConfigFile is the node name for compiler configurations in configuration file.
|
||||
packedGoFileName string // packedGoFileName specifies the file name for packing common folders into one single go file.
|
||||
}
|
||||
|
||||
const (
|
||||
cBuildDefaultFile = "main.go"
|
||||
cBuildBrief = `cross-building go project for lots of platforms`
|
||||
cBuildEg = `
|
||||
gf build main.go
|
||||
gf build main.go --ps public,template
|
||||
gf build main.go --cgo
|
||||
gf build main.go -m none
|
||||
gf build main.go -n my-app -a all -s all
|
||||
gf build main.go -n my-app -a amd64,386 -s linux -p .
|
||||
gf build main.go -n my-app -v 1.0 -a amd64,386 -s linux,windows,darwin -p ./docker/bin
|
||||
`
|
||||
cBuildDc = `
|
||||
The "build" command is most commonly used command, which is designed as a powerful wrapper for
|
||||
"go build" command for convenience cross-compiling usage.
|
||||
It provides much more features for building binary:
|
||||
1. Cross-Compiling for many platforms and architectures.
|
||||
2. Configuration file support for compiling.
|
||||
3. Build-In Variables.
|
||||
`
|
||||
cBuildAd = `
|
||||
PLATFORMS
|
||||
aix ppc64
|
||||
android 386,amd64,arm,arm64
|
||||
darwin amd64,arm64
|
||||
dragonfly amd64
|
||||
freebsd 386,amd64,arm
|
||||
illumos amd64
|
||||
ios arm64
|
||||
js wasm
|
||||
linux 386,amd64,arm,arm64,loong64,mips,mipsle,mips64,mips64le,ppc64,ppc64le,riscv64,s390x
|
||||
netbsd 386,amd64,arm
|
||||
openbsd 386,amd64,arm,arm64
|
||||
plan9 386,amd64,arm
|
||||
solaris amd64
|
||||
wasip1 wasm
|
||||
windows 386,amd64,arm,arm64
|
||||
`
|
||||
// https://golang.google.cn/doc/install/source
|
||||
cBuildPlatforms = `
|
||||
aix ppc64
|
||||
android 386
|
||||
android amd64
|
||||
android arm
|
||||
android arm64
|
||||
darwin amd64
|
||||
darwin arm64
|
||||
dragonfly amd64
|
||||
freebsd 386
|
||||
freebsd amd64
|
||||
freebsd arm
|
||||
illumos amd64
|
||||
ios arm64
|
||||
js wasm
|
||||
linux 386
|
||||
linux amd64
|
||||
linux arm
|
||||
linux arm64
|
||||
linux loong64
|
||||
linux mips
|
||||
linux mipsle
|
||||
linux mips64
|
||||
linux mips64le
|
||||
linux ppc64
|
||||
linux ppc64le
|
||||
linux riscv64
|
||||
linux s390x
|
||||
netbsd 386
|
||||
netbsd amd64
|
||||
netbsd arm
|
||||
openbsd 386
|
||||
openbsd amd64
|
||||
openbsd arm
|
||||
openbsd arm64
|
||||
plan9 386
|
||||
plan9 amd64
|
||||
plan9 arm
|
||||
solaris amd64
|
||||
wasip1 wasm
|
||||
windows 386
|
||||
windows amd64
|
||||
windows arm
|
||||
windows arm64
|
||||
`
|
||||
)
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cBuildBrief`: cBuildBrief,
|
||||
`cBuildDc`: cBuildDc,
|
||||
`cBuildEg`: cBuildEg,
|
||||
`cBuildAd`: cBuildAd,
|
||||
})
|
||||
}
|
||||
|
||||
type cBuildInput struct {
|
||||
g.Meta `name:"build" config:"gfcli.build"`
|
||||
File string `name:"FILE" arg:"true" brief:"building file path"`
|
||||
Name string `short:"n" name:"name" brief:"output binary name"`
|
||||
Version string `short:"v" name:"version" brief:"output binary version"`
|
||||
Arch string `short:"a" name:"arch" brief:"output binary architecture, multiple arch separated with ','"`
|
||||
System string `short:"s" name:"system" brief:"output binary system, multiple os separated with ','"`
|
||||
Output string `short:"o" name:"output" brief:"output binary path, used when building single binary file"`
|
||||
Path string `short:"p" name:"path" brief:"output binary directory path, default is '.'" d:"."`
|
||||
Extra string `short:"e" name:"extra" brief:"extra custom \"go build\" options"`
|
||||
Mod string `short:"m" name:"mod" brief:"like \"-mod\" option of \"go build\", use \"-m none\" to disable go module"`
|
||||
Cgo bool `short:"c" name:"cgo" brief:"enable or disable cgo feature, it's disabled in default" orphan:"true"`
|
||||
VarMap g.Map `short:"r" name:"varMap" brief:"custom built embedded variable into binary"`
|
||||
PackSrc string `short:"ps" name:"packSrc" brief:"pack one or more folders into one go file before building"`
|
||||
PackDst string `short:"pd" name:"packDst" brief:"temporary go file path for pack, this go file will be automatically removed after built" d:"internal/packed/build_pack_data.go"`
|
||||
ExitWhenError bool `short:"ew" name:"exitWhenError" brief:"exit building when any error occurs, specially for multiple arch and system buildings. default is false" orphan:"true"`
|
||||
DumpENV bool `short:"de" name:"dumpEnv" brief:"dump current go build environment before building binary" orphan:"true"`
|
||||
}
|
||||
|
||||
type cBuildOutput struct{}
|
||||
|
||||
func (c cBuild) Index(ctx context.Context, in cBuildInput) (out *cBuildOutput, err error) {
|
||||
mlog.SetHeaderPrint(true)
|
||||
|
||||
mlog.Debugf(`build command input: %+v`, in)
|
||||
// Necessary check.
|
||||
if gproc.SearchBinary("go") == "" {
|
||||
mlog.Fatalf(`command "go" not found in your environment, please install golang first to proceed this command`)
|
||||
}
|
||||
|
||||
var (
|
||||
parser = gcmd.ParserFromCtx(ctx)
|
||||
file = in.File
|
||||
)
|
||||
if file == "" {
|
||||
file = parser.GetArg(2).String()
|
||||
// Check and use the main.go file.
|
||||
if gfile.Exists(cBuildDefaultFile) {
|
||||
file = cBuildDefaultFile
|
||||
} else {
|
||||
mlog.Fatal("build file path is empty or main.go not found in current working directory")
|
||||
}
|
||||
}
|
||||
if in.Name == "" {
|
||||
in.Name = gfile.Name(file)
|
||||
}
|
||||
if len(in.Name) < 1 || in.Name == "*" {
|
||||
mlog.Fatal("name cannot be empty")
|
||||
}
|
||||
if in.Mod != "" && in.Mod != "none" {
|
||||
mlog.Debugf(`mod is %s`, in.Mod)
|
||||
if in.Extra == "" {
|
||||
in.Extra = fmt.Sprintf(`-mod=%s`, in.Mod)
|
||||
} else {
|
||||
in.Extra = fmt.Sprintf(`-mod=%s %s`, in.Mod, in.Extra)
|
||||
}
|
||||
}
|
||||
if in.Extra != "" {
|
||||
in.Extra += " "
|
||||
}
|
||||
var (
|
||||
customSystems = gstr.SplitAndTrim(in.System, ",")
|
||||
customArches = gstr.SplitAndTrim(in.Arch, ",")
|
||||
)
|
||||
if len(in.Version) > 0 {
|
||||
in.Path += "/" + in.Version
|
||||
}
|
||||
// System and arch checks.
|
||||
var (
|
||||
spaceRegex = regexp.MustCompile(`\s+`)
|
||||
platformMap = make(map[string]map[string]bool)
|
||||
)
|
||||
for _, line := range strings.Split(strings.TrimSpace(cBuildPlatforms), "\n") {
|
||||
line = gstr.Trim(line)
|
||||
line = spaceRegex.ReplaceAllString(line, " ")
|
||||
var (
|
||||
array = strings.Split(line, " ")
|
||||
system = strings.TrimSpace(array[0])
|
||||
arch = strings.TrimSpace(array[1])
|
||||
)
|
||||
if platformMap[system] == nil {
|
||||
platformMap[system] = make(map[string]bool)
|
||||
}
|
||||
platformMap[system][arch] = true
|
||||
}
|
||||
// Auto packing.
|
||||
if in.PackSrc != "" {
|
||||
if in.PackDst == "" {
|
||||
mlog.Fatal(`parameter "packDst" should not be empty when "packSrc" is used`)
|
||||
}
|
||||
if gfile.Exists(in.PackDst) && !gfile.IsFile(in.PackDst) {
|
||||
mlog.Fatalf(`parameter "packDst" path "%s" should be type of file not directory`, in.PackDst)
|
||||
}
|
||||
if !gfile.Exists(in.PackDst) {
|
||||
// Remove the go file that is automatically packed resource.
|
||||
defer func() {
|
||||
_ = gfile.RemoveFile(in.PackDst)
|
||||
mlog.Printf(`remove the automatically generated resource go file: %s`, in.PackDst)
|
||||
}()
|
||||
}
|
||||
// remove black space in separator.
|
||||
in.PackSrc, _ = gregex.ReplaceString(`,\s+`, `,`, in.PackSrc)
|
||||
packCmd := fmt.Sprintf(`gf pack %s %s --keepPath=true`, in.PackSrc, in.PackDst)
|
||||
mlog.Print(packCmd)
|
||||
gproc.MustShellRun(ctx, packCmd)
|
||||
}
|
||||
|
||||
// Injected information by building flags.
|
||||
ldFlags := fmt.Sprintf(
|
||||
`-X 'github.com/gogf/gf/v2/os/gbuild.builtInVarStr=%v'`,
|
||||
c.getBuildInVarStr(ctx, in),
|
||||
)
|
||||
|
||||
// start building
|
||||
mlog.Print("start building...")
|
||||
if in.Cgo {
|
||||
genv.MustSet("CGO_ENABLED", "1")
|
||||
} else {
|
||||
genv.MustSet("CGO_ENABLED", "0")
|
||||
}
|
||||
// print used go env
|
||||
if in.DumpENV {
|
||||
_, _ = Env.Index(ctx, cEnvInput{})
|
||||
}
|
||||
for system, item := range platformMap {
|
||||
if len(customSystems) > 0 && customSystems[0] != "all" && !gstr.InArray(customSystems, system) {
|
||||
continue
|
||||
}
|
||||
for arch := range item {
|
||||
if len(customArches) > 0 && customArches[0] != "all" && !gstr.InArray(customArches, arch) {
|
||||
continue
|
||||
}
|
||||
if len(customSystems) == 0 && len(customArches) == 0 {
|
||||
// Single binary building, output the binary to current working folder.
|
||||
// For example:
|
||||
// `gf build`
|
||||
// `gf build -o main.exe`
|
||||
c.doBinaryBuild(
|
||||
ctx, file,
|
||||
in.Output, in.Path,
|
||||
runtime.GOOS, runtime.GOARCH, in.Name, ldFlags, in.Extra,
|
||||
in.ExitWhenError,
|
||||
true,
|
||||
)
|
||||
} else {
|
||||
c.doBinaryBuild(
|
||||
ctx, file,
|
||||
in.Output, in.Path,
|
||||
system, arch, in.Name, ldFlags, in.Extra,
|
||||
in.ExitWhenError,
|
||||
false,
|
||||
)
|
||||
}
|
||||
// single binary building.
|
||||
if len(customSystems) == 0 && len(customArches) == 0 {
|
||||
goto buildDone
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
buildDone:
|
||||
mlog.Print("done!")
|
||||
return
|
||||
}
|
||||
|
||||
func (c cBuild) doBinaryBuild(
|
||||
ctx context.Context,
|
||||
filePath string,
|
||||
outputPath, dirPath string,
|
||||
system, arch, name, ldFlags, extra string,
|
||||
exitWhenError bool,
|
||||
singleBuild bool,
|
||||
) {
|
||||
var (
|
||||
cmd string
|
||||
ext string
|
||||
)
|
||||
// Cross-building, output the compiled binary to specified path.
|
||||
if system == "windows" {
|
||||
ext = ".exe"
|
||||
}
|
||||
genv.MustSet("GOOS", system)
|
||||
genv.MustSet("GOARCH", arch)
|
||||
|
||||
if outputPath != "" {
|
||||
outputPath = "-o " + outputPath
|
||||
} else {
|
||||
if dirPath == "" {
|
||||
dirPath = "."
|
||||
} else {
|
||||
dirPath = gstr.TrimRight(dirPath, "/")
|
||||
}
|
||||
if singleBuild {
|
||||
outputPath = fmt.Sprintf(
|
||||
"-o %s/%s%s",
|
||||
dirPath, name, ext,
|
||||
)
|
||||
} else {
|
||||
outputPath = fmt.Sprintf(
|
||||
"-o %s/%s/%s%s",
|
||||
dirPath, system+"_"+arch, name, ext,
|
||||
)
|
||||
}
|
||||
}
|
||||
cmd = fmt.Sprintf(
|
||||
`go build %s -ldflags "%s" %s%s`,
|
||||
outputPath, ldFlags, extra, filePath,
|
||||
)
|
||||
mlog.Debug(fmt.Sprintf("build for GOOS=%s GOARCH=%s", system, arch))
|
||||
mlog.Debug(cmd)
|
||||
// It's not necessary printing the complete command string, filtering ldFlags.
|
||||
cmdShow, _ := gregex.ReplaceString(`\s+(-ldflags ".+?")\s+`, " ", cmd)
|
||||
mlog.Print(cmdShow)
|
||||
if result, err := gproc.ShellExec(ctx, cmd); err != nil {
|
||||
mlog.Printf(
|
||||
"failed to build, os:%s, arch:%s, error:\n%s\n\n%s\n",
|
||||
system, arch, gstr.Trim(result),
|
||||
`you may use command option "--debug" to enable debug info and check the details`,
|
||||
)
|
||||
if exitWhenError {
|
||||
os.Exit(1)
|
||||
}
|
||||
} else {
|
||||
mlog.Debug(gstr.Trim(result))
|
||||
}
|
||||
}
|
||||
|
||||
// getBuildInVarStr retrieves and returns the custom build-in variables in configuration
|
||||
// file as json.
|
||||
func (c cBuild) getBuildInVarStr(ctx context.Context, in cBuildInput) string {
|
||||
buildInVarMap := in.VarMap
|
||||
if buildInVarMap == nil {
|
||||
buildInVarMap = make(g.Map)
|
||||
}
|
||||
buildInVarMap[gbuild.BuiltGit] = c.getGitCommit(ctx)
|
||||
buildInVarMap[gbuild.BuiltTime] = gtime.Now().String()
|
||||
buildInVarMap[gbuild.BuiltVersion] = in.Version
|
||||
b, err := json.Marshal(buildInVarMap)
|
||||
if err != nil {
|
||||
mlog.Fatal(err)
|
||||
}
|
||||
return gbase64.EncodeToString(b)
|
||||
}
|
||||
|
||||
// getGitCommit retrieves and returns the latest git commit hash string if present.
|
||||
func (c cBuild) getGitCommit(ctx context.Context) string {
|
||||
if gproc.SearchBinary("git") == "" {
|
||||
return ""
|
||||
}
|
||||
var (
|
||||
cmd = `git log -1 --format="%cd %H" --date=format:"%Y-%m-%d %H:%M:%S"`
|
||||
s, _ = gproc.ShellExec(ctx, cmd)
|
||||
)
|
||||
mlog.Debug(cmd)
|
||||
if s != "" {
|
||||
if !gstr.Contains(s, "fatal") {
|
||||
return gstr.Trim(s)
|
||||
}
|
||||
}
|
||||
return ""
|
||||
}
|
||||
184
cmd/gf/internal/cmd/cmd_doc.go
Normal file
184
cmd/gf/internal/cmd/cmd_doc.go
Normal file
@ -0,0 +1,184 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"io"
|
||||
"net/http"
|
||||
"os"
|
||||
"path"
|
||||
"path/filepath"
|
||||
"time"
|
||||
|
||||
"github.com/gogf/gf/v2/encoding/gcompress"
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
const (
|
||||
GitName = "gf-site"
|
||||
BranchName = "gh-pages"
|
||||
|
||||
SiteFileName = GitName + "-" + BranchName
|
||||
// DocURL is the download address of the document
|
||||
DocURL = "https://github.com/gogf/" + GitName + "/archive/refs/heads/" + BranchName + ".zip"
|
||||
)
|
||||
|
||||
var (
|
||||
Doc = cDoc{}
|
||||
)
|
||||
|
||||
type cDoc struct {
|
||||
g.Meta `name:"doc" brief:"download https://pages.goframe.org/ to run locally"`
|
||||
}
|
||||
|
||||
type cDocInput struct {
|
||||
g.Meta `name:"doc" config:"gfcli.doc"`
|
||||
Path string `short:"p" name:"path" brief:"download docs directory path, default is \"%temp%/goframe\""`
|
||||
Port int `short:"o" name:"port" brief:"http server port, default is 8080" d:"8080"`
|
||||
Update bool `short:"u" name:"update" brief:"clean docs directory and update docs"`
|
||||
Clean bool `short:"c" name:"clean" brief:"clean docs directory"`
|
||||
Proxy string `short:"x" name:"proxy" brief:"proxy for download, such as https://hub.gitmirror.com/;https://ghproxy.com/;https://ghproxy.net/;https://ghps.cc/"`
|
||||
}
|
||||
|
||||
type cDocOutput struct{}
|
||||
|
||||
func (c cDoc) Index(ctx context.Context, in cDocInput) (out *cDocOutput, err error) {
|
||||
docs := NewDocSetting(ctx, in)
|
||||
mlog.Print("Directory where the document is downloaded:", docs.TempDir)
|
||||
if in.Clean {
|
||||
mlog.Print("Cleaning document directory")
|
||||
err = docs.Clean()
|
||||
if err != nil {
|
||||
mlog.Print("Failed to clean document directory:", err)
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
if in.Update {
|
||||
mlog.Print("Cleaning old document directory")
|
||||
err = docs.Clean()
|
||||
if err != nil {
|
||||
mlog.Print("Failed to clean old document directory:", err)
|
||||
return
|
||||
}
|
||||
}
|
||||
err = docs.DownloadDoc()
|
||||
if err != nil {
|
||||
mlog.Print("Failed to download document:", err)
|
||||
return
|
||||
}
|
||||
|
||||
http.Handle("/", http.FileServer(http.Dir(docs.DocDir)))
|
||||
mlog.Printf("Access address http://127.0.0.1:%d in %s", in.Port, docs.DocDir)
|
||||
err = http.ListenAndServe(fmt.Sprintf(":%d", in.Port), nil)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DocSetting doc setting
|
||||
type DocSetting struct {
|
||||
TempDir string
|
||||
DocURL string
|
||||
DocDir string
|
||||
DocZipFile string
|
||||
}
|
||||
|
||||
// NewDocSetting new DocSetting
|
||||
func NewDocSetting(ctx context.Context, in cDocInput) *DocSetting {
|
||||
fileName := SiteFileName + ".zip"
|
||||
tempDir := in.Path
|
||||
if tempDir == "" {
|
||||
tempDir = gfile.Temp("goframe/docs")
|
||||
} else {
|
||||
tempDir = gfile.Abs(path.Join(tempDir, "docs"))
|
||||
}
|
||||
|
||||
return &DocSetting{
|
||||
TempDir: filepath.FromSlash(tempDir),
|
||||
DocDir: filepath.FromSlash(path.Join(tempDir, SiteFileName)),
|
||||
DocURL: in.Proxy + DocURL,
|
||||
DocZipFile: filepath.FromSlash(path.Join(tempDir, fileName)),
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Clean cleans the temporary directory
|
||||
func (d *DocSetting) Clean() error {
|
||||
if _, err := os.Stat(d.TempDir); err == nil {
|
||||
err = gfile.RemoveAll(d.TempDir)
|
||||
if err != nil {
|
||||
mlog.Print("Failed to delete temporary directory:", err)
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// DownloadDoc download the document
|
||||
func (d *DocSetting) DownloadDoc() error {
|
||||
if _, err := os.Stat(d.TempDir); err != nil {
|
||||
err = gfile.Mkdir(d.TempDir)
|
||||
if err != nil {
|
||||
mlog.Print("Failed to create temporary directory:", err)
|
||||
return nil
|
||||
}
|
||||
}
|
||||
// Check if the file exists
|
||||
if _, err := os.Stat(d.DocDir); err == nil {
|
||||
mlog.Print("Document already exists, no need to download and unzip")
|
||||
return nil
|
||||
}
|
||||
|
||||
if _, err := os.Stat(d.DocZipFile); err == nil {
|
||||
mlog.Print("File already exists, no need to download")
|
||||
} else {
|
||||
mlog.Printf("File does not exist, start downloading: %s", d.DocURL)
|
||||
startTime := time.Now()
|
||||
// Download the file
|
||||
resp, err := http.Get(d.DocURL)
|
||||
if err != nil {
|
||||
mlog.Print("Failed to download file:", err)
|
||||
return err
|
||||
}
|
||||
defer resp.Body.Close()
|
||||
|
||||
// Create the file
|
||||
out, err := os.Create(d.DocZipFile)
|
||||
if err != nil {
|
||||
mlog.Print("Failed to create file:", err)
|
||||
return err
|
||||
}
|
||||
defer out.Close()
|
||||
|
||||
// Write the response body to the file
|
||||
_, err = io.Copy(out, resp.Body)
|
||||
if err != nil {
|
||||
mlog.Print("Failed to write file:", err)
|
||||
return err
|
||||
}
|
||||
mlog.Printf("Download successful, time-consuming: %v", time.Since(startTime))
|
||||
}
|
||||
|
||||
mlog.Print("Start unzipping the file...")
|
||||
// Unzip the file
|
||||
err := gcompress.UnZipFile(d.DocZipFile, d.TempDir)
|
||||
if err != nil {
|
||||
mlog.Print("Failed to unzip the file, please run again:", err)
|
||||
_ = gfile.RemoveFile(d.DocZipFile)
|
||||
return err
|
||||
}
|
||||
|
||||
mlog.Print("Download and unzip successful")
|
||||
return nil
|
||||
}
|
||||
179
cmd/gf/internal/cmd/cmd_docker.go
Normal file
179
cmd/gf/internal/cmd/cmd_docker.go
Normal file
@ -0,0 +1,179 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"runtime"
|
||||
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/os/gproc"
|
||||
"github.com/gogf/gf/v2/text/gstr"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
var (
|
||||
Docker = cDocker{}
|
||||
)
|
||||
|
||||
type cDocker struct {
|
||||
g.Meta `name:"docker" usage:"{cDockerUsage}" brief:"{cDockerBrief}" eg:"{cDockerEg}" dc:"{cDockerDc}"`
|
||||
}
|
||||
|
||||
const (
|
||||
cDockerUsage = `gf docker [MAIN] [OPTION]`
|
||||
cDockerBrief = `build docker image for current GoFrame project`
|
||||
cDockerEg = `
|
||||
gf docker
|
||||
gf docker -t hub.docker.com/john/image:tag
|
||||
gf docker -p -t hub.docker.com/john/image:tag
|
||||
gf docker main.go
|
||||
gf docker main.go -t hub.docker.com/john/image:tag
|
||||
gf docker main.go -t hub.docker.com/john/image:tag
|
||||
gf docker main.go -p -t hub.docker.com/john/image:tag
|
||||
gf docker main.go -p -tp ["hub.docker.com/john","hub.docker.com/smith"] -tn image:tag
|
||||
`
|
||||
cDockerDc = `
|
||||
The "docker" command builds the GF project to a docker images.
|
||||
It runs "gf build" firstly to compile the project to binary file.
|
||||
It then runs "docker build" command automatically to generate the docker image.
|
||||
You should have docker installed, and there must be a Dockerfile in the root of the project.
|
||||
`
|
||||
cDockerMainBrief = `main file path for "gf build", it's "main.go" in default. empty string for no binary build`
|
||||
cDockerBuildBrief = `binary build options before docker image build, it's "-a amd64 -s linux" in default`
|
||||
cDockerFileBrief = `file path of the Dockerfile. it's "manifest/docker/Dockerfile" in default`
|
||||
cDockerShellBrief = `path of the shell file which is executed before docker build`
|
||||
cDockerPushBrief = `auto push the docker image to docker registry if "-t" option passed`
|
||||
cDockerTagBrief = `full tag for this docker, pattern like "xxx.xxx.xxx/image:tag"`
|
||||
cDockerTagNameBrief = `tag name for this docker, pattern like "image:tag". this option is required with TagPrefixes`
|
||||
cDockerTagPrefixesBrief = `tag prefixes for this docker, which are used for docker push. this option is required with TagName`
|
||||
cDockerExtraBrief = `extra build options passed to "docker image"`
|
||||
)
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cDockerUsage`: cDockerUsage,
|
||||
`cDockerBrief`: cDockerBrief,
|
||||
`cDockerEg`: cDockerEg,
|
||||
`cDockerDc`: cDockerDc,
|
||||
`cDockerMainBrief`: cDockerMainBrief,
|
||||
`cDockerFileBrief`: cDockerFileBrief,
|
||||
`cDockerShellBrief`: cDockerShellBrief,
|
||||
`cDockerBuildBrief`: cDockerBuildBrief,
|
||||
`cDockerPushBrief`: cDockerPushBrief,
|
||||
`cDockerTagBrief`: cDockerTagBrief,
|
||||
`cDockerTagNameBrief`: cDockerTagNameBrief,
|
||||
`cDockerTagPrefixesBrief`: cDockerTagPrefixesBrief,
|
||||
`cDockerExtraBrief`: cDockerExtraBrief,
|
||||
})
|
||||
}
|
||||
|
||||
type cDockerInput struct {
|
||||
g.Meta `name:"docker" config:"gfcli.docker"`
|
||||
Main string `name:"MAIN" arg:"true" brief:"{cDockerMainBrief}" d:"main.go"`
|
||||
File string `name:"file" short:"f" brief:"{cDockerFileBrief}" d:"manifest/docker/Dockerfile"`
|
||||
Shell string `name:"shell" short:"s" brief:"{cDockerShellBrief}" d:"manifest/docker/docker.sh"`
|
||||
Build string `name:"build" short:"b" brief:"{cDockerBuildBrief}"`
|
||||
Tag string `name:"tag" short:"t" brief:"{cDockerTagBrief}"`
|
||||
TagName string `name:"tagName" short:"tn" brief:"{cDockerTagNameBrief}" v:"required-with:TagPrefixes"`
|
||||
TagPrefixes []string `name:"tagPrefixes" short:"tp" brief:"{cDockerTagPrefixesBrief}" v:"required-with:TagName"`
|
||||
Push bool `name:"push" short:"p" brief:"{cDockerPushBrief}" orphan:"true"`
|
||||
Extra string `name:"extra" short:"e" brief:"{cDockerExtraBrief}"`
|
||||
}
|
||||
|
||||
type cDockerOutput struct{}
|
||||
|
||||
func (c cDocker) Index(ctx context.Context, in cDockerInput) (out *cDockerOutput, err error) {
|
||||
// Necessary check.
|
||||
if gproc.SearchBinary("docker") == "" {
|
||||
mlog.Fatalf(`command "docker" not found in your environment, please install docker first to proceed this command`)
|
||||
}
|
||||
|
||||
mlog.Debugf(`docker command input: %+v`, in)
|
||||
|
||||
// Binary build.
|
||||
if in.Main != "" && in.Build != "" {
|
||||
in.Build += " --exitWhenError"
|
||||
if in.Main != "" {
|
||||
if err = gproc.ShellRun(ctx, fmt.Sprintf(`gf build %s %s`, in.Main, in.Build)); err != nil {
|
||||
mlog.Debugf(`build binary failed with error: %+v`, err)
|
||||
return
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Shell executing.
|
||||
if in.Shell != "" && gfile.Exists(in.Shell) {
|
||||
if err = c.exeDockerShell(ctx, in.Shell); err != nil {
|
||||
mlog.Debugf(`build docker failed with error: %+v`, err)
|
||||
return
|
||||
}
|
||||
}
|
||||
// Docker build.
|
||||
var (
|
||||
dockerBuildOptions string
|
||||
dockerTags []string
|
||||
dockerTagBase string
|
||||
)
|
||||
if len(in.TagPrefixes) > 0 {
|
||||
for _, tagPrefix := range in.TagPrefixes {
|
||||
tagPrefix = gstr.TrimRight(tagPrefix, "/")
|
||||
dockerTags = append(dockerTags, fmt.Sprintf(`%s/%s`, tagPrefix, in.TagName))
|
||||
}
|
||||
}
|
||||
if len(dockerTags) == 0 {
|
||||
dockerTags = []string{in.Tag}
|
||||
}
|
||||
for i, dockerTag := range dockerTags {
|
||||
if i > 0 {
|
||||
err = gproc.ShellRun(ctx, fmt.Sprintf(`docker tag %s %s`, dockerTagBase, dockerTag))
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
continue
|
||||
}
|
||||
dockerTagBase = dockerTag
|
||||
dockerBuildOptions = ""
|
||||
if dockerTag != "" {
|
||||
dockerBuildOptions = fmt.Sprintf(`-t %s`, dockerTag)
|
||||
}
|
||||
if in.Extra != "" {
|
||||
dockerBuildOptions = fmt.Sprintf(`%s %s`, dockerBuildOptions, in.Extra)
|
||||
}
|
||||
err = gproc.ShellRun(ctx, fmt.Sprintf(`docker build -f %s . %s`, in.File, dockerBuildOptions))
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
// Docker push.
|
||||
if !in.Push {
|
||||
return
|
||||
}
|
||||
for _, dockerTag := range dockerTags {
|
||||
if dockerTag == "" {
|
||||
continue
|
||||
}
|
||||
err = gproc.ShellRun(ctx, fmt.Sprintf(`docker push %s`, dockerTag))
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func (c cDocker) exeDockerShell(ctx context.Context, shellFilePath string) error {
|
||||
if gfile.ExtName(shellFilePath) == "sh" && runtime.GOOS == "windows" {
|
||||
mlog.Debugf(`ignore shell file "%s", as it cannot be run on windows system`, shellFilePath)
|
||||
return nil
|
||||
}
|
||||
return gproc.ShellRun(ctx, gfile.GetContents(shellFilePath))
|
||||
}
|
||||
89
cmd/gf/internal/cmd/cmd_env.go
Normal file
89
cmd/gf/internal/cmd/cmd_env.go
Normal file
@ -0,0 +1,89 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
|
||||
"github.com/olekukonko/tablewriter"
|
||||
"github.com/olekukonko/tablewriter/renderer"
|
||||
"github.com/olekukonko/tablewriter/tw"
|
||||
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gproc"
|
||||
"github.com/gogf/gf/v2/text/gregex"
|
||||
"github.com/gogf/gf/v2/text/gstr"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
var (
|
||||
Env = cEnv{}
|
||||
)
|
||||
|
||||
type cEnv struct {
|
||||
g.Meta `name:"env" brief:"show current Golang environment variables"`
|
||||
}
|
||||
|
||||
type cEnvInput struct {
|
||||
g.Meta `name:"env"`
|
||||
}
|
||||
|
||||
type cEnvOutput struct{}
|
||||
|
||||
func (c cEnv) Index(ctx context.Context, in cEnvInput) (out *cEnvOutput, err error) {
|
||||
result, execErr := gproc.ShellExec(ctx, "go env")
|
||||
// Note: go env may return non-zero exit code when there are warnings (e.g., invalid characters in env vars),
|
||||
// but it still outputs valid environment variables. So we only fail if result is empty.
|
||||
if result == "" {
|
||||
if execErr != nil {
|
||||
mlog.Fatal(execErr)
|
||||
}
|
||||
mlog.Fatal(`retrieving Golang environment variables failed, did you install Golang?`)
|
||||
}
|
||||
var (
|
||||
lines = gstr.Split(result, "\n")
|
||||
buffer = bytes.NewBuffer(nil)
|
||||
)
|
||||
array := make([][]string, 0)
|
||||
for _, line := range lines {
|
||||
line = gstr.Trim(line)
|
||||
if line == "" {
|
||||
continue
|
||||
}
|
||||
if gstr.Pos(line, "set ") == 0 {
|
||||
line = line[4:]
|
||||
}
|
||||
match, _ := gregex.MatchString(`(.+?)=(.*)`, line)
|
||||
if len(match) < 3 {
|
||||
// Skip lines that don't match key=value format (e.g., warning messages from go env)
|
||||
mlog.Debugf(`invalid Golang environment variable: "%s"`, line)
|
||||
continue
|
||||
}
|
||||
array = append(array, []string{gstr.Trim(match[1]), gstr.Trim(match[2])})
|
||||
}
|
||||
table := tablewriter.NewTable(buffer,
|
||||
tablewriter.WithRenderer(renderer.NewBlueprint(tw.Rendition{
|
||||
Settings: tw.Settings{
|
||||
Separators: tw.Separators{BetweenRows: tw.Off, BetweenColumns: tw.On},
|
||||
},
|
||||
Symbols: tw.NewSymbols(tw.StyleASCII),
|
||||
})),
|
||||
tablewriter.WithConfig(tablewriter.Config{
|
||||
Row: tw.CellConfig{
|
||||
Formatting: tw.CellFormatting{AutoWrap: tw.WrapNone},
|
||||
Alignment: tw.CellAlignment{PerColumn: []tw.Align{tw.AlignLeft, tw.AlignLeft}},
|
||||
ColMaxWidths: tw.CellWidth{Global: 84},
|
||||
},
|
||||
}),
|
||||
)
|
||||
table.Bulk(array)
|
||||
table.Render()
|
||||
mlog.Print(buffer.String())
|
||||
return
|
||||
}
|
||||
152
cmd/gf/internal/cmd/cmd_fix.go
Normal file
152
cmd/gf/internal/cmd/cmd_fix.go
Normal file
@ -0,0 +1,152 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/gogf/gf/v2/errors/gerror"
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/os/gproc"
|
||||
"github.com/gogf/gf/v2/text/gregex"
|
||||
"github.com/gogf/gf/v2/text/gstr"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
var (
|
||||
Fix = cFix{}
|
||||
)
|
||||
|
||||
type cFix struct {
|
||||
g.Meta `name:"fix" brief:"auto fixing codes after upgrading to new GoFrame version" usage:"gf fix" `
|
||||
}
|
||||
|
||||
type cFixInput struct {
|
||||
g.Meta `name:"fix"`
|
||||
Path string `name:"path" short:"p" brief:"directory path, it uses current working directory in default"`
|
||||
Version string `name:"version" short:"v" brief:"custom specified version to fix, leave it empty to auto detect"`
|
||||
}
|
||||
|
||||
type cFixOutput struct{}
|
||||
|
||||
type cFixItem struct {
|
||||
Version string
|
||||
Func func(version string) error
|
||||
}
|
||||
|
||||
func (c cFix) Index(ctx context.Context, in cFixInput) (out *cFixOutput, err error) {
|
||||
|
||||
if in.Path == "" {
|
||||
in.Path = gfile.Pwd()
|
||||
}
|
||||
if in.Version == "" {
|
||||
in.Version, err = c.autoDetectVersion(in)
|
||||
if err != nil {
|
||||
mlog.Fatal(err)
|
||||
}
|
||||
if in.Version == "" {
|
||||
mlog.Print(`no GoFrame usage found, exit fixing`)
|
||||
return
|
||||
}
|
||||
mlog.Debugf(`current GoFrame version auto detect "%s"`, in.Version)
|
||||
}
|
||||
|
||||
if !gproc.IsChild() {
|
||||
mlog.Printf(`start auto fixing directory path "%s"...`, in.Path)
|
||||
defer mlog.Print(`done!`)
|
||||
}
|
||||
|
||||
err = c.doFix(in)
|
||||
return
|
||||
}
|
||||
|
||||
func (c cFix) doFix(in cFixInput) (err error) {
|
||||
|
||||
var items = []cFixItem{
|
||||
{Version: "v2.3", Func: c.doFixV23},
|
||||
{Version: "v2.5", Func: c.doFixV25},
|
||||
}
|
||||
for _, item := range items {
|
||||
if gstr.CompareVersionGo(in.Version, item.Version) < 0 {
|
||||
mlog.Debugf(
|
||||
`current GoFrame or contrib package version "%s" is lesser than "%s", nothing to do`,
|
||||
in.Version, item.Version,
|
||||
)
|
||||
continue
|
||||
}
|
||||
if err = item.Func(in.Version); err != nil {
|
||||
return
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// doFixV23 fixes code when upgrading to GoFrame v2.3.
|
||||
func (c cFix) doFixV23(version string) error {
|
||||
replaceFunc := func(path, content string) string {
|
||||
// gdb.TX from struct to interface.
|
||||
content = gstr.Replace(content, "*gdb.TX", "gdb.TX")
|
||||
// function name changes for package gtcp/gudp.
|
||||
if gstr.Contains(content, "/gf/v2/net/gtcp") || gstr.Contains(content, "/gf/v2/net/gudp") {
|
||||
content = gstr.ReplaceByMap(content, g.MapStrStr{
|
||||
".SetSendDeadline": ".SetDeadlineSend",
|
||||
".SetReceiveDeadline": ".SetDeadlineRecv",
|
||||
".SetReceiveBufferWait": ".SetBufferWaitRecv",
|
||||
})
|
||||
}
|
||||
return content
|
||||
}
|
||||
return gfile.ReplaceDirFunc(replaceFunc, ".", "*.go", true)
|
||||
}
|
||||
|
||||
// doFixV25 fixes code when upgrading to GoFrame v2.5.
|
||||
func (c cFix) doFixV25(version string) (err error) {
|
||||
replaceFunc := func(path, content string) string {
|
||||
content, err = c.doFixV25Content(content)
|
||||
return content
|
||||
}
|
||||
return gfile.ReplaceDirFunc(replaceFunc, ".", "*.go", true)
|
||||
}
|
||||
|
||||
func (c cFix) doFixV25Content(content string) (newContent string, err error) {
|
||||
newContent = content
|
||||
if gstr.Contains(content, `.BindHookHandlerByMap(`) {
|
||||
var pattern = `\.BindHookHandlerByMap\((.+?), map\[string\]ghttp\.HandlerFunc`
|
||||
newContent, err = gregex.ReplaceString(
|
||||
pattern,
|
||||
`.BindHookHandlerByMap($1, map[ghttp.HookName]ghttp.HandlerFunc`,
|
||||
content,
|
||||
)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func (c cFix) autoDetectVersion(in cFixInput) (string, error) {
|
||||
var (
|
||||
err error
|
||||
path = gfile.Join(in.Path, "go.mod")
|
||||
version string
|
||||
)
|
||||
if !gfile.Exists(path) {
|
||||
return "", gerror.Newf(`"%s" not found in current working directory`, path)
|
||||
}
|
||||
err = gfile.ReadLines(path, func(line string) error {
|
||||
array := gstr.SplitAndTrim(line, " ")
|
||||
if len(array) > 0 {
|
||||
if gstr.HasPrefix(array[0], gfPackage) {
|
||||
version = array[1]
|
||||
}
|
||||
}
|
||||
return nil
|
||||
})
|
||||
if err != nil {
|
||||
mlog.Fatal(err)
|
||||
}
|
||||
return version, nil
|
||||
}
|
||||
42
cmd/gf/internal/cmd/cmd_gen.go
Normal file
42
cmd/gf/internal/cmd/cmd_gen.go
Normal file
@ -0,0 +1,42 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
)
|
||||
|
||||
var (
|
||||
Gen = cGen{}
|
||||
)
|
||||
|
||||
type cGen struct {
|
||||
g.Meta `name:"gen" brief:"{cGenBrief}" dc:"{cGenDc}"`
|
||||
cGenDao
|
||||
cGenEnums
|
||||
cGenCtrl
|
||||
cGenPb
|
||||
cGenPbEntity
|
||||
cGenService
|
||||
}
|
||||
|
||||
const (
|
||||
cGenBrief = `automatically generate go files for dao/do/entity/pb/pbentity`
|
||||
cGenDc = `
|
||||
The "gen" command is designed for multiple generating purposes.
|
||||
It's currently supporting generating go files for ORM models, protobuf and protobuf entity files.
|
||||
Please use "gf gen dao -h" for specified type help.
|
||||
`
|
||||
)
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cGenBrief`: cGenBrief,
|
||||
`cGenDc`: cGenDc,
|
||||
})
|
||||
}
|
||||
15
cmd/gf/internal/cmd/cmd_gen_ctrl.go
Normal file
15
cmd/gf/internal/cmd/cmd_gen_ctrl.go
Normal file
@ -0,0 +1,15 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/cmd/genctrl"
|
||||
)
|
||||
|
||||
type (
|
||||
cGenCtrl = genctrl.CGenCtrl
|
||||
)
|
||||
22
cmd/gf/internal/cmd/cmd_gen_dao.go
Normal file
22
cmd/gf/internal/cmd/cmd_gen_dao.go
Normal file
@ -0,0 +1,22 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
_ "github.com/gogf/gf/contrib/drivers/clickhouse/v2"
|
||||
_ "github.com/gogf/gf/contrib/drivers/mssql/v2"
|
||||
_ "github.com/gogf/gf/contrib/drivers/mysql/v2"
|
||||
_ "github.com/gogf/gf/contrib/drivers/oracle/v2"
|
||||
_ "github.com/gogf/gf/contrib/drivers/pgsql/v2"
|
||||
_ "github.com/gogf/gf/contrib/drivers/sqlite/v2"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/cmd/gendao"
|
||||
)
|
||||
|
||||
type (
|
||||
cGenDao = gendao.CGenDao
|
||||
)
|
||||
13
cmd/gf/internal/cmd/cmd_gen_dao_dm.go
Normal file
13
cmd/gf/internal/cmd/cmd_gen_dao_dm.go
Normal file
@ -0,0 +1,13 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
//go:build dm
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
_ "github.com/gogf/gf/contrib/drivers/dm/v2"
|
||||
)
|
||||
15
cmd/gf/internal/cmd/cmd_gen_enums.go
Normal file
15
cmd/gf/internal/cmd/cmd_gen_enums.go
Normal file
@ -0,0 +1,15 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/cmd/genenums"
|
||||
)
|
||||
|
||||
type (
|
||||
cGenEnums = genenums.CGenEnums
|
||||
)
|
||||
13
cmd/gf/internal/cmd/cmd_gen_pb.go
Normal file
13
cmd/gf/internal/cmd/cmd_gen_pb.go
Normal file
@ -0,0 +1,13 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import "github.com/gogf/gf/cmd/gf/v2/internal/cmd/genpb"
|
||||
|
||||
type (
|
||||
cGenPb = genpb.CGenPb
|
||||
)
|
||||
13
cmd/gf/internal/cmd/cmd_gen_pbentity.go
Normal file
13
cmd/gf/internal/cmd/cmd_gen_pbentity.go
Normal file
@ -0,0 +1,13 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import "github.com/gogf/gf/cmd/gf/v2/internal/cmd/genpbentity"
|
||||
|
||||
type (
|
||||
cGenPbEntity = genpbentity.CGenPbEntity
|
||||
)
|
||||
15
cmd/gf/internal/cmd/cmd_gen_service.go
Normal file
15
cmd/gf/internal/cmd/cmd_gen_service.go
Normal file
@ -0,0 +1,15 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/cmd/genservice"
|
||||
)
|
||||
|
||||
type (
|
||||
cGenService = genservice.CGenService
|
||||
)
|
||||
444
cmd/gf/internal/cmd/cmd_init.go
Normal file
444
cmd/gf/internal/cmd/cmd_init.go
Normal file
@ -0,0 +1,444 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"bufio"
|
||||
"context"
|
||||
"fmt"
|
||||
"os"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gcmd"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/os/gproc"
|
||||
"github.com/gogf/gf/v2/os/gres"
|
||||
"github.com/gogf/gf/v2/text/gstr"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/cmd/geninit"
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/allyes"
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/utils"
|
||||
)
|
||||
|
||||
var (
|
||||
// Init .
|
||||
Init = cInit{}
|
||||
)
|
||||
|
||||
type cInit struct {
|
||||
g.Meta `name:"init" brief:"{cInitBrief}" eg:"{cInitEg}"`
|
||||
}
|
||||
|
||||
const (
|
||||
cInitRepoPrefix = `github.com/gogf/`
|
||||
cInitMonoRepo = `template-mono`
|
||||
cInitMonoRepoApp = `template-mono-app`
|
||||
cInitSingleRepo = `template-single`
|
||||
cInitBrief = `create and initialize an empty GoFrame project`
|
||||
cInitEg = `
|
||||
gf init my-project
|
||||
gf init my-mono-repo -m
|
||||
gf init my-mono-repo -a
|
||||
gf init my-project -u
|
||||
gf init my-project -g "github.com/myorg/myproject"
|
||||
gf init -r github.com/gogf/template-single my-project
|
||||
gf init -r github.com/gogf/examples/httpserver/jwt my-jwt
|
||||
gf init -r github.com/gogf/gf/cmd/gf/v2@v2.9.7 mygf
|
||||
gf init -r github.com/gogf/gf/cmd/gf/v2 mygf -s
|
||||
gf init -i
|
||||
`
|
||||
cInitNameBrief = `
|
||||
name for the project. It will create a folder with NAME in current directory.
|
||||
The NAME will also be the module name for the project.
|
||||
`
|
||||
// cInitGitDir the git directory
|
||||
cInitGitDir = ".git"
|
||||
// cInitGitignore the gitignore file
|
||||
cInitGitignore = ".gitignore"
|
||||
)
|
||||
|
||||
// defaultTemplates is the list of predefined templates for interactive selection
|
||||
var defaultTemplates = []struct {
|
||||
Name string
|
||||
Repo string
|
||||
Desc string
|
||||
}{
|
||||
{"template-single", "github.com/gogf/template-single", "Single project template"},
|
||||
{"template-mono", "github.com/gogf/template-mono", "Mono-repo project template"},
|
||||
}
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cInitBrief`: cInitBrief,
|
||||
`cInitEg`: cInitEg,
|
||||
`cInitNameBrief`: cInitNameBrief,
|
||||
})
|
||||
}
|
||||
|
||||
type cInitInput struct {
|
||||
g.Meta `name:"init"`
|
||||
Name string `name:"NAME" arg:"true" brief:"{cInitNameBrief}"`
|
||||
Mono bool `name:"mono" short:"m" brief:"initialize a mono-repo instead a single-repo" orphan:"true"`
|
||||
MonoApp bool `name:"monoApp" short:"a" brief:"initialize a mono-repo-app instead a single-repo" orphan:"true"`
|
||||
Update bool `name:"update" short:"u" brief:"update to the latest goframe version" orphan:"true"`
|
||||
Module string `name:"module" short:"g" brief:"custom go module"`
|
||||
Repo string `name:"repo" short:"r" brief:"remote repository URL for template download"`
|
||||
SelectVer bool `name:"select" short:"s" brief:"enable interactive version selection for remote template" orphan:"true"`
|
||||
Interactive bool `name:"interactive" short:"i" brief:"enable interactive mode to select template" orphan:"true"`
|
||||
}
|
||||
|
||||
type cInitOutput struct{}
|
||||
|
||||
func (c cInit) Index(ctx context.Context, in cInitInput) (out *cInitOutput, err error) {
|
||||
// Check if using remote template mode
|
||||
if in.Repo != "" || in.Interactive {
|
||||
return c.initFromRemote(ctx, in)
|
||||
}
|
||||
|
||||
// If no name provided and no remote mode, enter interactive mode
|
||||
if in.Name == "" {
|
||||
return c.initInteractive(ctx, in)
|
||||
}
|
||||
|
||||
// Default: use built-in template
|
||||
return c.initFromBuiltin(ctx, in)
|
||||
}
|
||||
|
||||
// initFromRemote initializes project from remote repository
|
||||
func (c cInit) initFromRemote(ctx context.Context, in cInitInput) (out *cInitOutput, err error) {
|
||||
repo := in.Repo
|
||||
name := in.Name
|
||||
|
||||
// If interactive mode and no repo specified, let user select
|
||||
if in.Interactive && repo == "" {
|
||||
var modPath string
|
||||
var upgradeDeps bool
|
||||
repo, name, modPath, upgradeDeps, err = interactiveSelectTemplate()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if modPath != "" {
|
||||
in.Module = modPath
|
||||
}
|
||||
if upgradeDeps {
|
||||
in.Update = true
|
||||
}
|
||||
}
|
||||
|
||||
if repo == "" {
|
||||
return nil, fmt.Errorf("repository URL is required for remote template mode")
|
||||
}
|
||||
|
||||
// Default name to repo basename if empty
|
||||
if name == "" {
|
||||
name = gfile.Basename(repo)
|
||||
mlog.Printf("Using repository basename as project name: %s", name)
|
||||
}
|
||||
|
||||
mlog.Print("initializing from remote template...")
|
||||
|
||||
opts := &geninit.ProcessOptions{
|
||||
SelectVersion: in.SelectVer,
|
||||
ModulePath: in.Module,
|
||||
UpgradeDeps: in.Update,
|
||||
}
|
||||
|
||||
if err = geninit.Process(ctx, repo, name, opts); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
mlog.Print("initialization done!")
|
||||
if name != "" && name != "." {
|
||||
mlog.Printf(`you can now run "cd %s && gf run main.go" to start your journey, enjoy!`, name)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// initFromBuiltin initializes project from built-in template
|
||||
func (c cInit) initFromBuiltin(ctx context.Context, in cInitInput) (out *cInitOutput, err error) {
|
||||
var overwrote = false
|
||||
if !gfile.IsEmpty(in.Name) && !allyes.Check() {
|
||||
s := gcmd.Scanf(`the folder "%s" is not empty, files might be overwrote, continue? [y/n]: `, in.Name)
|
||||
if strings.EqualFold(s, "n") {
|
||||
return
|
||||
}
|
||||
overwrote = true
|
||||
}
|
||||
mlog.Print("initializing...")
|
||||
|
||||
// Create project folder and files.
|
||||
var (
|
||||
templateRepoName string
|
||||
gitignoreFile = in.Name + "/" + cInitGitignore
|
||||
)
|
||||
|
||||
if in.Mono {
|
||||
templateRepoName = cInitMonoRepo
|
||||
} else if in.MonoApp {
|
||||
templateRepoName = cInitMonoRepoApp
|
||||
} else {
|
||||
templateRepoName = cInitSingleRepo
|
||||
}
|
||||
|
||||
err = gres.Export(templateRepoName, in.Name, gres.ExportOption{
|
||||
RemovePrefix: templateRepoName,
|
||||
})
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
// build ignoreFiles from the .gitignore file
|
||||
ignoreFiles := make([]string, 0, 10)
|
||||
ignoreFiles = append(ignoreFiles, cInitGitDir)
|
||||
// in.MonoApp is a mono-repo-app, it should ignore the .gitignore file
|
||||
if overwrote && !in.MonoApp {
|
||||
err = gfile.ReadLines(gitignoreFile, func(line string) error {
|
||||
// Add only hidden files or directories
|
||||
// If other directories are added, it may cause the entire directory to be ignored
|
||||
// such as 'main' in the .gitignore file, but the path is ' D:\main\my-project '
|
||||
if line != "" && strings.HasPrefix(line, ".") {
|
||||
ignoreFiles = append(ignoreFiles, line)
|
||||
}
|
||||
return nil
|
||||
})
|
||||
|
||||
// if not found the .gitignore file will skip os.ErrNotExist error
|
||||
if err != nil && !os.IsNotExist(err) {
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
// Get template name and module name.
|
||||
if in.Module == "" {
|
||||
in.Module = gfile.Basename(gfile.RealPath(in.Name))
|
||||
}
|
||||
if in.MonoApp {
|
||||
pwd := gfile.Pwd() + string(os.PathSeparator) + in.Name
|
||||
in.Module = utils.GetImportPath(pwd)
|
||||
}
|
||||
|
||||
// Replace template name to project name.
|
||||
err = gfile.ReplaceDirFunc(func(path, content string) string {
|
||||
for _, ignoreFile := range ignoreFiles {
|
||||
if strings.Contains(path, ignoreFile) {
|
||||
return content
|
||||
}
|
||||
}
|
||||
mlog.Debugf("replace %s %s to %s", path, cInitRepoPrefix+templateRepoName, in.Module)
|
||||
return gstr.Replace(gfile.GetContents(path), cInitRepoPrefix+templateRepoName, in.Module)
|
||||
}, in.Name, "*", true)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
// Format the generated Go files using go/format (not goimports).
|
||||
// utils.GoFmt uses imports.Process which may remove local import paths that cannot
|
||||
// be resolved in the GOPATH or module cache right after generation (e.g. "myapp/api/hello/v1").
|
||||
geninit.FormatGoFiles(in.Name)
|
||||
|
||||
// Update the GoFrame version.
|
||||
if in.Update {
|
||||
mlog.Print("update goframe...")
|
||||
// go get -u github.com/gogf/gf/v2@latest
|
||||
updateCommand := `go get -u github.com/gogf/gf/v2@latest`
|
||||
if in.Name != "." {
|
||||
updateCommand = fmt.Sprintf(`cd %s && %s`, in.Name, updateCommand)
|
||||
}
|
||||
if err = gproc.ShellRun(ctx, updateCommand); err != nil {
|
||||
mlog.Fatal(err)
|
||||
}
|
||||
// go mod tidy
|
||||
gomModTidyCommand := `go mod tidy`
|
||||
if in.Name != "." {
|
||||
gomModTidyCommand = fmt.Sprintf(`cd %s && %s`, in.Name, gomModTidyCommand)
|
||||
}
|
||||
if err = gproc.ShellRun(ctx, gomModTidyCommand); err != nil {
|
||||
mlog.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
mlog.Print("initialization done! ")
|
||||
if !in.Mono {
|
||||
enjoyCommand := `gf run main.go`
|
||||
if in.Name != "." {
|
||||
enjoyCommand = fmt.Sprintf(`cd %s && %s`, in.Name, enjoyCommand)
|
||||
}
|
||||
mlog.Printf(`you can now run "%s" to start your journey, enjoy!`, enjoyCommand)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// initInteractive enters interactive mode when no arguments provided
|
||||
func (c cInit) initInteractive(ctx context.Context, in cInitInput) (out *cInitOutput, err error) {
|
||||
reader := bufio.NewReader(os.Stdin)
|
||||
|
||||
// Ask user which mode to use
|
||||
fmt.Println("\nPlease select initialization mode:")
|
||||
fmt.Println(strings.Repeat("-", 50))
|
||||
fmt.Println(" [1] Built-in template (default)")
|
||||
fmt.Println(" [2] Remote template")
|
||||
fmt.Println(strings.Repeat("-", 50))
|
||||
|
||||
fmt.Print("Select mode [1-2] (default: 1): ")
|
||||
input, err := reader.ReadString('\n')
|
||||
if err != nil {
|
||||
mlog.Fatalf("failed to read input: %v", err)
|
||||
return
|
||||
}
|
||||
input = strings.TrimSpace(input)
|
||||
|
||||
if input == "2" {
|
||||
in.Interactive = true
|
||||
return c.initFromRemote(ctx, in)
|
||||
}
|
||||
|
||||
// Built-in template mode
|
||||
fmt.Println("\nPlease select project type:")
|
||||
fmt.Println(strings.Repeat("-", 50))
|
||||
fmt.Println(" [1] Single project (default)")
|
||||
fmt.Println(" [2] Mono-repo project")
|
||||
fmt.Println(" [3] Mono-repo app")
|
||||
fmt.Println(strings.Repeat("-", 50))
|
||||
|
||||
fmt.Print("Select type [1-3] (default: 1): ")
|
||||
input, err = reader.ReadString('\n')
|
||||
if err != nil {
|
||||
mlog.Fatalf("failed to read input: %v", err)
|
||||
return
|
||||
}
|
||||
input = strings.TrimSpace(input)
|
||||
|
||||
switch input {
|
||||
case "2":
|
||||
in.Mono = true
|
||||
case "3":
|
||||
in.MonoApp = true
|
||||
}
|
||||
|
||||
// Get project name
|
||||
for {
|
||||
fmt.Print("Enter project name: ")
|
||||
input, err = reader.ReadString('\n')
|
||||
if err != nil {
|
||||
mlog.Fatalf("failed to read input: %v", err)
|
||||
return
|
||||
}
|
||||
in.Name = strings.TrimSpace(input)
|
||||
if in.Name != "" {
|
||||
break
|
||||
}
|
||||
fmt.Println("Project name cannot be empty")
|
||||
}
|
||||
|
||||
// Get module path (optional)
|
||||
fmt.Printf("Enter Go module path (leave empty to use \"%s\"): ", in.Name)
|
||||
input, err = reader.ReadString('\n')
|
||||
if err != nil {
|
||||
mlog.Fatalf("failed to read input: %v", err)
|
||||
return
|
||||
}
|
||||
in.Module = strings.TrimSpace(input)
|
||||
|
||||
// Ask about update
|
||||
fmt.Print("Update to latest GoFrame version? [y/N]: ")
|
||||
input, err = reader.ReadString('\n')
|
||||
if err != nil {
|
||||
mlog.Fatalf("failed to read input: %v", err)
|
||||
return
|
||||
}
|
||||
input = strings.TrimSpace(strings.ToLower(input))
|
||||
in.Update = input == "y" || input == "yes"
|
||||
|
||||
fmt.Println()
|
||||
return c.initFromBuiltin(ctx, in)
|
||||
}
|
||||
|
||||
// interactiveSelectTemplate prompts user to select a template interactively
|
||||
func interactiveSelectTemplate() (repo, name, modPath string, upgradeDeps bool, err error) {
|
||||
reader := bufio.NewReader(os.Stdin)
|
||||
|
||||
// 1. Select template
|
||||
fmt.Println("\nPlease select a project template:")
|
||||
fmt.Println(strings.Repeat("-", 50))
|
||||
for i, t := range defaultTemplates {
|
||||
fmt.Printf(" [%d] %s - %s\n", i+1, t.Name, t.Desc)
|
||||
}
|
||||
fmt.Printf(" [%d] Custom repository URL\n", len(defaultTemplates)+1)
|
||||
fmt.Println(strings.Repeat("-", 50))
|
||||
|
||||
for {
|
||||
fmt.Printf("Select template [1-%d]: ", len(defaultTemplates)+1)
|
||||
input, err := reader.ReadString('\n')
|
||||
if err != nil {
|
||||
return "", "", "", false, fmt.Errorf("failed to read template selection: %w", err)
|
||||
}
|
||||
input = strings.TrimSpace(input)
|
||||
|
||||
idx, e := strconv.Atoi(input)
|
||||
if e != nil || idx < 1 || idx > len(defaultTemplates)+1 {
|
||||
fmt.Printf("Invalid selection, please enter a number between 1-%d\n", len(defaultTemplates)+1)
|
||||
continue
|
||||
}
|
||||
|
||||
if idx <= len(defaultTemplates) {
|
||||
repo = defaultTemplates[idx-1].Repo
|
||||
fmt.Printf("Selected: %s\n\n", repo)
|
||||
} else {
|
||||
// Custom URL
|
||||
fmt.Print("Enter repository URL: ")
|
||||
input, err = reader.ReadString('\n')
|
||||
if err != nil {
|
||||
return "", "", "", false, fmt.Errorf("failed to read repository URL: %w", err)
|
||||
}
|
||||
repo = strings.TrimSpace(input)
|
||||
if repo == "" {
|
||||
fmt.Println("Repository URL cannot be empty")
|
||||
continue
|
||||
}
|
||||
}
|
||||
break
|
||||
}
|
||||
|
||||
// 2. Enter project name
|
||||
for {
|
||||
fmt.Print("Enter project name: ")
|
||||
input, err := reader.ReadString('\n')
|
||||
if err != nil {
|
||||
return "", "", "", false, fmt.Errorf("failed to read project name: %w", err)
|
||||
}
|
||||
name = strings.TrimSpace(input)
|
||||
if name == "" {
|
||||
fmt.Println("Project name cannot be empty")
|
||||
continue
|
||||
}
|
||||
break
|
||||
}
|
||||
|
||||
// 3. Enter module path (optional)
|
||||
fmt.Printf("Enter Go module path (leave empty to use \"%s\"): ", name)
|
||||
input, err := reader.ReadString('\n')
|
||||
if err != nil {
|
||||
return "", "", "", false, fmt.Errorf("failed to read module path: %w", err)
|
||||
}
|
||||
modPath = strings.TrimSpace(input)
|
||||
|
||||
// 4. Ask about upgrade
|
||||
fmt.Print("Upgrade dependencies to latest (go get -u)? [y/N]: ")
|
||||
input, err = reader.ReadString('\n')
|
||||
if err != nil {
|
||||
return "", "", "", false, fmt.Errorf("failed to read upgrade confirmation: %w", err)
|
||||
}
|
||||
input = strings.TrimSpace(strings.ToLower(input))
|
||||
upgradeDeps = input == "y" || input == "yes"
|
||||
|
||||
fmt.Println()
|
||||
return repo, name, modPath, upgradeDeps, nil
|
||||
}
|
||||
34
cmd/gf/internal/cmd/cmd_install.go
Normal file
34
cmd/gf/internal/cmd/cmd_install.go
Normal file
@ -0,0 +1,34 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/service"
|
||||
)
|
||||
|
||||
var (
|
||||
Install = cInstall{}
|
||||
)
|
||||
|
||||
type cInstall struct {
|
||||
g.Meta `name:"install" brief:"install gf binary to system (might need root/admin permission)"`
|
||||
}
|
||||
|
||||
type cInstallInput struct {
|
||||
g.Meta `name:"install"`
|
||||
}
|
||||
|
||||
type cInstallOutput struct{}
|
||||
|
||||
func (c cInstall) Index(ctx context.Context, in cInstallInput) (out *cInstallOutput, err error) {
|
||||
err = service.Install.Run(ctx)
|
||||
return
|
||||
}
|
||||
104
cmd/gf/internal/cmd/cmd_pack.go
Normal file
104
cmd/gf/internal/cmd/cmd_pack.go
Normal file
@ -0,0 +1,104 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"strings"
|
||||
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gcmd"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/os/gres"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/allyes"
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
var (
|
||||
Pack = cPack{}
|
||||
)
|
||||
|
||||
type cPack struct {
|
||||
g.Meta `name:"pack" usage:"{cPackUsage}" brief:"{cPackBrief}" eg:"{cPackEg}"`
|
||||
}
|
||||
|
||||
const (
|
||||
cPackUsage = `gf pack SRC DST`
|
||||
cPackBrief = `packing any file/directory to a resource file, or a go file`
|
||||
cPackEg = `
|
||||
gf pack public data.bin
|
||||
gf pack public,template data.bin
|
||||
gf pack public,template packed/data.go
|
||||
gf pack public,template,config packed/data.go
|
||||
gf pack public,template,config packed/data.go -n=packed -p=/var/www/my-app
|
||||
gf pack /var/www/public packed/data.go -n=packed
|
||||
`
|
||||
cPackSrcBrief = `source path for packing, which can be multiple source paths.`
|
||||
cPackDstBrief = `
|
||||
destination file path for packed file. if extension of the filename is ".go" and "-n" option is given,
|
||||
it enables packing SRC to go file, or else it packs SRC into a binary file.
|
||||
`
|
||||
cPackNameBrief = `package name for output go file, it's set as its directory name if no name passed`
|
||||
cPackPrefixBrief = `prefix for each file packed into the resource file`
|
||||
cPackKeepPathBrief = `keep the source path from system to resource file, usually for relative path`
|
||||
)
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cPackUsage`: cPackUsage,
|
||||
`cPackBrief`: cPackBrief,
|
||||
`cPackEg`: cPackEg,
|
||||
`cPackSrcBrief`: cPackSrcBrief,
|
||||
`cPackDstBrief`: cPackDstBrief,
|
||||
`cPackNameBrief`: cPackNameBrief,
|
||||
`cPackPrefixBrief`: cPackPrefixBrief,
|
||||
`cPackKeepPathBrief`: cPackKeepPathBrief,
|
||||
})
|
||||
}
|
||||
|
||||
type cPackInput struct {
|
||||
g.Meta `name:"pack" config:"gfcli.pack"`
|
||||
Src string `name:"SRC" arg:"true" v:"required" brief:"{cPackSrcBrief}"`
|
||||
Dst string `name:"DST" arg:"true" v:"required" brief:"{cPackDstBrief}"`
|
||||
Name string `name:"name" short:"n" brief:"{cPackNameBrief}"`
|
||||
Prefix string `name:"prefix" short:"p" brief:"{cPackPrefixBrief}"`
|
||||
KeepPath bool `name:"keepPath" short:"k" brief:"{cPackKeepPathBrief}" orphan:"true"`
|
||||
}
|
||||
|
||||
type cPackOutput struct{}
|
||||
|
||||
func (c cPack) Index(ctx context.Context, in cPackInput) (out *cPackOutput, err error) {
|
||||
if gfile.Exists(in.Dst) && gfile.IsDir(in.Dst) {
|
||||
mlog.Fatalf("DST path '%s' cannot be a directory", in.Dst)
|
||||
}
|
||||
if !gfile.IsEmpty(in.Dst) && !allyes.Check() {
|
||||
s := gcmd.Scanf("path '%s' is not empty, files might be overwrote, continue? [y/n]: ", in.Dst)
|
||||
if strings.EqualFold(s, "n") {
|
||||
return
|
||||
}
|
||||
}
|
||||
if in.Name == "" && gfile.ExtName(in.Dst) == "go" {
|
||||
in.Name = gfile.Basename(gfile.Dir(in.Dst))
|
||||
}
|
||||
var option = gres.Option{
|
||||
Prefix: in.Prefix,
|
||||
KeepPath: in.KeepPath,
|
||||
}
|
||||
if in.Name != "" {
|
||||
if err = gres.PackToGoFileWithOption(in.Src, in.Dst, in.Name, option); err != nil {
|
||||
mlog.Fatalf("pack failed: %v", err)
|
||||
}
|
||||
} else {
|
||||
if err = gres.PackToFileWithOption(in.Src, in.Dst, option); err != nil {
|
||||
mlog.Fatalf("pack failed: %v", err)
|
||||
}
|
||||
}
|
||||
mlog.Print("done!")
|
||||
return
|
||||
}
|
||||
444
cmd/gf/internal/cmd/cmd_run.go
Normal file
444
cmd/gf/internal/cmd/cmd_run.go
Normal file
@ -0,0 +1,444 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/gogf/gf/v2/container/gtype"
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/os/gfsnotify"
|
||||
"github.com/gogf/gf/v2/os/gproc"
|
||||
"github.com/gogf/gf/v2/os/gtime"
|
||||
"github.com/gogf/gf/v2/os/gtimer"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
var Run = cRun{}
|
||||
|
||||
type cRun struct {
|
||||
g.Meta `name:"run" usage:"{cRunUsage}" brief:"{cRunBrief}" eg:"{cRunEg}" dc:"{cRunDc}"`
|
||||
}
|
||||
|
||||
type watchPath struct {
|
||||
Path string
|
||||
Recursive bool
|
||||
}
|
||||
|
||||
type cRunApp struct {
|
||||
File string // Go run file name.
|
||||
Path string // Directory storing built binary.
|
||||
Options string // Extra "go run" options.
|
||||
Args string // Custom arguments.
|
||||
WatchPaths []string // Watch paths for live reload.
|
||||
IgnorePatterns []string // Custom ignore patterns.
|
||||
}
|
||||
|
||||
const (
|
||||
cRunUsage = `gf run FILE [OPTION]`
|
||||
cRunBrief = `running go codes with hot-compiled-like feature`
|
||||
cRunEg = `
|
||||
gf run main.go
|
||||
gf run main.go --args "server -p 8080"
|
||||
gf run main.go -mod=vendor
|
||||
gf run main.go -w internal,api
|
||||
gf run main.go -i ".git,node_modules"
|
||||
`
|
||||
cRunDc = `
|
||||
The "run" command is used for running go codes with hot-compiled-like feature,
|
||||
which compiles and runs the go codes asynchronously when codes change.
|
||||
`
|
||||
cRunFileBrief = `building file path.`
|
||||
cRunPathBrief = `output directory path for built binary file. it's "./" in default`
|
||||
cRunExtraBrief = `the same options as "go run"/"go build" except some options as follows defined`
|
||||
cRunArgsBrief = `custom arguments for your process`
|
||||
cRunWatchPathsBrief = `watch additional paths for live reload, separated by ",". i.e. "internal,api"`
|
||||
cRunIgnorePatternBrief = `custom ignore patterns for watch, separated by ",". i.e. ".git,node_modules". default patterns: node_modules, vendor, .*, _*. Glob syntax: "*" matches any chars, "?" matches single char, "[abc]" matches char class. Note: patterns match directory names only, not paths`
|
||||
)
|
||||
|
||||
var process *gproc.Process
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cRunUsage`: cRunUsage,
|
||||
`cRunBrief`: cRunBrief,
|
||||
`cRunEg`: cRunEg,
|
||||
`cRunDc`: cRunDc,
|
||||
`cRunFileBrief`: cRunFileBrief,
|
||||
`cRunPathBrief`: cRunPathBrief,
|
||||
`cRunExtraBrief`: cRunExtraBrief,
|
||||
`cRunArgsBrief`: cRunArgsBrief,
|
||||
`cRunWatchPathsBrief`: cRunWatchPathsBrief,
|
||||
`cRunIgnorePatternBrief`: cRunIgnorePatternBrief,
|
||||
})
|
||||
}
|
||||
|
||||
type (
|
||||
cRunInput struct {
|
||||
g.Meta `name:"run" config:"gfcli.run"`
|
||||
File string `name:"FILE" arg:"true" brief:"{cRunFileBrief}" v:"required"`
|
||||
Path string `name:"path" short:"p" brief:"{cRunPathBrief}" d:"./"`
|
||||
Extra string `name:"extra" short:"e" brief:"{cRunExtraBrief}"`
|
||||
Args string `name:"args" short:"a" brief:"{cRunArgsBrief}"`
|
||||
WatchPaths []string `name:"watchPaths" short:"w" brief:"{cRunWatchPathsBrief}"`
|
||||
IgnorePatterns []string `name:"ignorePatterns" short:"i" brief:"{cRunIgnorePatternBrief}"`
|
||||
}
|
||||
cRunOutput struct{}
|
||||
)
|
||||
|
||||
func (c cRun) Index(ctx context.Context, in cRunInput) (out *cRunOutput, err error) {
|
||||
if !gfile.Exists(in.File) {
|
||||
mlog.Fatalf(`given file "%s" not found`, in.File)
|
||||
}
|
||||
if !gfile.IsFile(in.File) {
|
||||
mlog.Fatalf(`given "%s" is not a file`, in.File)
|
||||
}
|
||||
// Necessary check.
|
||||
if gproc.SearchBinary("go") == "" {
|
||||
mlog.Fatalf(`command "go" not found in your environment, please install golang first to proceed this command`)
|
||||
}
|
||||
|
||||
// Parse comma-separated values in WatchPaths
|
||||
if len(in.WatchPaths) > 0 {
|
||||
in.WatchPaths = parseCommaSeparatedArgs(in.WatchPaths)
|
||||
mlog.Printf("watchPaths: %v", in.WatchPaths)
|
||||
}
|
||||
|
||||
// Parse comma-separated values in IgnorePatterns
|
||||
if len(in.IgnorePatterns) > 0 {
|
||||
in.IgnorePatterns = parseCommaSeparatedArgs(in.IgnorePatterns)
|
||||
mlog.Printf("ignorePatterns: %v", in.IgnorePatterns)
|
||||
}
|
||||
|
||||
app := &cRunApp{
|
||||
File: in.File,
|
||||
Path: filepath.FromSlash(in.Path),
|
||||
Options: in.Extra,
|
||||
Args: in.Args,
|
||||
WatchPaths: in.WatchPaths,
|
||||
IgnorePatterns: in.IgnorePatterns,
|
||||
}
|
||||
dirty := gtype.NewBool()
|
||||
|
||||
outputPath := app.genOutputPath()
|
||||
callbackFunc := func(event *gfsnotify.Event) {
|
||||
if !event.IsWrite() && !event.IsCreate() && !event.IsRemove() && !event.IsRename() {
|
||||
return
|
||||
}
|
||||
|
||||
// Check if the file extension is 'go'.
|
||||
if gfile.ExtName(event.Path) != "go" {
|
||||
return
|
||||
}
|
||||
|
||||
// Variable `dirty` is used for running the changes only one in one second.
|
||||
if !dirty.Cas(false, true) {
|
||||
return
|
||||
}
|
||||
|
||||
// With some delay in case of multiple code changes in very short interval.
|
||||
gtimer.SetTimeout(ctx, 1500*gtime.MS, func(ctx context.Context) {
|
||||
defer dirty.Set(false)
|
||||
mlog.Printf(`watched file changes: %s`, event.String())
|
||||
app.Run(ctx, outputPath)
|
||||
})
|
||||
}
|
||||
|
||||
// Get directories to watch (recursive or non-recursive monitoring).
|
||||
watchPaths := app.getWatchPaths()
|
||||
for _, wp := range watchPaths {
|
||||
option := gfsnotify.WatchOption{NoRecursive: !wp.Recursive}
|
||||
_, err = gfsnotify.Add(wp.Path, callbackFunc, option)
|
||||
if err != nil {
|
||||
mlog.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
go app.Run(ctx, outputPath)
|
||||
|
||||
gproc.AddSigHandlerShutdown(func(sig os.Signal) {
|
||||
app.End(ctx, sig, outputPath)
|
||||
os.Exit(0)
|
||||
})
|
||||
gproc.Listen()
|
||||
|
||||
select {}
|
||||
}
|
||||
|
||||
func (app *cRunApp) Run(ctx context.Context, outputPath string) {
|
||||
// Rebuild and run the codes.
|
||||
mlog.Printf("build: %s", app.File)
|
||||
|
||||
// In case of `pipe: too many open files` error.
|
||||
// Build the app.
|
||||
buildCommand := fmt.Sprintf(
|
||||
`go build -o %s %s %s`,
|
||||
outputPath,
|
||||
app.Options,
|
||||
app.File,
|
||||
)
|
||||
mlog.Print(buildCommand)
|
||||
result, err := gproc.ShellExec(ctx, buildCommand)
|
||||
if err != nil {
|
||||
mlog.Printf("build error: \n%s%s", result, err.Error())
|
||||
return
|
||||
}
|
||||
// Kill the old process if build successfully.
|
||||
if process != nil {
|
||||
if err := process.Kill(); err != nil {
|
||||
mlog.Debugf("kill process error: %s", err.Error())
|
||||
}
|
||||
}
|
||||
// Run the binary file.
|
||||
runCommand := fmt.Sprintf(`%s %s`, outputPath, app.Args)
|
||||
mlog.Print(runCommand)
|
||||
if runtime.GOOS == "windows" {
|
||||
// Special handling for windows platform.
|
||||
// DO NOT USE "cmd /c" command.
|
||||
process = gproc.NewProcess(outputPath, strings.Fields(app.Args))
|
||||
} else {
|
||||
process = gproc.NewProcessCmd(runCommand, nil)
|
||||
}
|
||||
if pid, err := process.Start(ctx); err != nil {
|
||||
mlog.Printf("build running error: %s", err.Error())
|
||||
} else {
|
||||
mlog.Printf("build running pid: %d", pid)
|
||||
}
|
||||
}
|
||||
|
||||
func (app *cRunApp) End(ctx context.Context, sig os.Signal, outputPath string) {
|
||||
// Delete the binary file.
|
||||
// firstly, kill the process.
|
||||
if process != nil {
|
||||
if sig != nil && runtime.GOOS != "windows" {
|
||||
if err := process.Signal(sig); err != nil {
|
||||
mlog.Debugf("send signal to process error: %s", err.Error())
|
||||
if err := process.Kill(); err != nil {
|
||||
mlog.Debugf("kill process error: %s", err.Error())
|
||||
}
|
||||
} else {
|
||||
waitCtx, cancel := context.WithTimeout(ctx, 30*time.Second)
|
||||
defer cancel()
|
||||
done := make(chan error, 1)
|
||||
go func() {
|
||||
select {
|
||||
case <-waitCtx.Done():
|
||||
done <- waitCtx.Err()
|
||||
case done <- process.Wait():
|
||||
}
|
||||
}()
|
||||
err := <-done
|
||||
if err != nil {
|
||||
mlog.Debugf("process wait error: %s", err.Error())
|
||||
if err := process.Kill(); err != nil {
|
||||
mlog.Debugf("kill process error: %s", err.Error())
|
||||
}
|
||||
} else {
|
||||
mlog.Debug("process exited gracefully")
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if err := process.Kill(); err != nil {
|
||||
mlog.Debugf("kill process error: %s", err.Error())
|
||||
}
|
||||
}
|
||||
}
|
||||
if err := gfile.RemoveFile(outputPath); err != nil {
|
||||
mlog.Printf("delete binary file error: %s", err.Error())
|
||||
} else {
|
||||
mlog.Printf("deleted binary file: %s", outputPath)
|
||||
}
|
||||
}
|
||||
|
||||
func (app *cRunApp) genOutputPath() (outputPath string) {
|
||||
outputPath = gfile.Join(app.Path, gfile.Name(app.File))
|
||||
if runtime.GOOS == "windows" {
|
||||
outputPath += ".exe"
|
||||
if gfile.Exists(outputPath) {
|
||||
renamePath := outputPath + "~"
|
||||
if err := gfile.Rename(outputPath, renamePath); err != nil {
|
||||
mlog.Print(err)
|
||||
}
|
||||
// Clean up the renamed old binary file
|
||||
defer func() {
|
||||
if gfile.Exists(renamePath) {
|
||||
_ = gfile.Remove(renamePath)
|
||||
}
|
||||
}()
|
||||
}
|
||||
}
|
||||
return filepath.FromSlash(outputPath)
|
||||
}
|
||||
|
||||
// getWatchPaths uses DFS to find the minimal set of directories to watch.
|
||||
// Rule: if a directory and all its descendants have no ignored subdirectories, watch it;
|
||||
// otherwise, recurse into valid children and watch the current directory non-recursively.
|
||||
func (app *cRunApp) getWatchPaths() []watchPath {
|
||||
roots := []string{"."}
|
||||
if len(app.WatchPaths) > 0 {
|
||||
roots = app.WatchPaths
|
||||
}
|
||||
|
||||
// Use custom ignore patterns if provided, otherwise use default.
|
||||
ignorePatterns := defaultIgnorePatterns
|
||||
if len(app.IgnorePatterns) > 0 {
|
||||
ignorePatterns = app.IgnorePatterns
|
||||
}
|
||||
|
||||
var watchPaths []watchPath
|
||||
|
||||
for _, root := range roots {
|
||||
absRoot := gfile.RealPath(root)
|
||||
if absRoot == "" {
|
||||
mlog.Printf("watch path '%s' not found, skipping", root)
|
||||
continue
|
||||
}
|
||||
if isIgnoredDirName(absRoot, ignorePatterns) {
|
||||
continue
|
||||
}
|
||||
app.collectWatchPaths(absRoot, ignorePatterns, &watchPaths)
|
||||
}
|
||||
|
||||
if len(watchPaths) == 0 {
|
||||
mlog.Printf("no directories to watch, using current directory")
|
||||
if absCur := gfile.RealPath("."); absCur != "" {
|
||||
return []watchPath{{Path: absCur, Recursive: true}}
|
||||
}
|
||||
return []watchPath{{Path: ".", Recursive: true}}
|
||||
}
|
||||
|
||||
mlog.Printf("watching %d paths", len(watchPaths))
|
||||
for _, wp := range watchPaths {
|
||||
recursiveStr := "recursive"
|
||||
if !wp.Recursive {
|
||||
recursiveStr = "non-recursive"
|
||||
}
|
||||
mlog.Debugf(" - %s (%s)", wp.Path, recursiveStr)
|
||||
}
|
||||
return watchPaths
|
||||
}
|
||||
|
||||
// collectWatchPaths performs a DFS traversal to collect the minimal set of directories to watch.
|
||||
// Returns true if the directory or any of its descendants contains ignored directories.
|
||||
// Rule: if a directory has no ignored descendants at any depth, watch it recursively;
|
||||
// otherwise, watch it non-recursively and recurse into valid children.
|
||||
func (app *cRunApp) collectWatchPaths(dir string, ignorePatterns []string, watchPaths *[]watchPath) bool {
|
||||
entries, err := gfile.ScanDir(dir, "*", false)
|
||||
if err != nil {
|
||||
mlog.Printf("scan directory '%s' error: %s", dir, err.Error())
|
||||
// If we can't scan the directory, add it to watch list as fallback
|
||||
*watchPaths = append(*watchPaths, watchPath{Path: dir, Recursive: true})
|
||||
return false
|
||||
}
|
||||
|
||||
// First pass: identify valid subdirectories and check for directly ignored children
|
||||
var validSubDirs []string
|
||||
hasIgnoredChild := false
|
||||
for _, entry := range entries {
|
||||
if !gfile.IsDir(entry) {
|
||||
continue
|
||||
}
|
||||
if isIgnoredDirName(entry, ignorePatterns) {
|
||||
hasIgnoredChild = true
|
||||
} else {
|
||||
validSubDirs = append(validSubDirs, entry)
|
||||
}
|
||||
}
|
||||
|
||||
// If already has ignored child, we know this dir needs non-recursive watch
|
||||
if hasIgnoredChild {
|
||||
*watchPaths = append(*watchPaths, watchPath{Path: dir, Recursive: false})
|
||||
for _, subDir := range validSubDirs {
|
||||
app.collectWatchPaths(subDir, ignorePatterns, watchPaths)
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
// No ignored children, but need to check descendants recursively
|
||||
// Collect results from all subdirectories first
|
||||
subResults := make([]bool, len(validSubDirs))
|
||||
subWatchPaths := make([][]watchPath, len(validSubDirs))
|
||||
hasIgnoredDescendant := false
|
||||
|
||||
for i, subDir := range validSubDirs {
|
||||
var subPaths []watchPath
|
||||
subResults[i] = app.collectWatchPaths(subDir, ignorePatterns, &subPaths)
|
||||
subWatchPaths[i] = subPaths
|
||||
if subResults[i] {
|
||||
hasIgnoredDescendant = true
|
||||
}
|
||||
}
|
||||
|
||||
if !hasIgnoredDescendant {
|
||||
// No ignored descendants at any depth, watch this directory recursively
|
||||
*watchPaths = append(*watchPaths, watchPath{Path: dir, Recursive: true})
|
||||
return false
|
||||
}
|
||||
|
||||
// Has ignored descendants, watch current directory non-recursively
|
||||
// and add all collected subdirectory watch paths
|
||||
*watchPaths = append(*watchPaths, watchPath{Path: dir, Recursive: false})
|
||||
for _, subPaths := range subWatchPaths {
|
||||
*watchPaths = append(*watchPaths, subPaths...)
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
// defaultIgnorePatterns contains glob patterns for directory names that should be ignored when watching.
|
||||
// These directories typically contain third-party code or non-source files.
|
||||
// Supported glob syntax (filepath.Match):
|
||||
// - "*" matches any sequence of non-separator characters
|
||||
// - "?" matches any single non-separator character
|
||||
// - "[abc]" matches any character in the bracket
|
||||
// - "[a-z]" matches any character in the range
|
||||
// - "[^abc]" or "[!abc]" matches any character not in the bracket
|
||||
//
|
||||
// Note: patterns match directory base names only, not full paths (no "/" or path separators allowed).
|
||||
var defaultIgnorePatterns = []string{
|
||||
"node_modules",
|
||||
"vendor",
|
||||
".*", // All hidden directories (covers .git, .svn, .hg, .idea, .vscode, etc.)
|
||||
"_*", // Directories starting with underscore
|
||||
}
|
||||
|
||||
// isIgnoredDirName checks if a directory name matches any ignored pattern.
|
||||
// It accepts either a full path or just the directory name, but only matches against the base name.
|
||||
// Note: patterns should not contain "/" as they only match directory names, not paths.
|
||||
func isIgnoredDirName(name string, ignorePatterns []string) bool {
|
||||
baseName := gfile.Basename(name)
|
||||
for _, pattern := range ignorePatterns {
|
||||
if matched, _ := filepath.Match(pattern, baseName); matched {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
// parseCommaSeparatedArgs parses command line arguments that may contain comma-separated values.
|
||||
// It handles both single argument with commas (e.g., "a,b,c") and multiple arguments.
|
||||
func parseCommaSeparatedArgs(args []string) []string {
|
||||
var result []string
|
||||
for _, arg := range args {
|
||||
parts := strings.Split(arg, ",")
|
||||
for _, part := range parts {
|
||||
trimmed := strings.TrimSpace(part)
|
||||
if trimmed != "" {
|
||||
result = append(result, trimmed)
|
||||
}
|
||||
}
|
||||
}
|
||||
return result
|
||||
}
|
||||
174
cmd/gf/internal/cmd/cmd_tpl.go
Normal file
174
cmd/gf/internal/cmd/cmd_tpl.go
Normal file
@ -0,0 +1,174 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/gogf/gf/v2/encoding/gjson"
|
||||
"github.com/gogf/gf/v2/errors/gerror"
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/text/gstr"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
"github.com/gogf/gf/v2/util/gutil"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
)
|
||||
|
||||
var (
|
||||
Tpl = cTpl{}
|
||||
)
|
||||
|
||||
type cTpl struct {
|
||||
g.Meta `name:"tpl" brief:"{cTplBrief}" dc:"{cTplDc}"`
|
||||
}
|
||||
|
||||
const (
|
||||
cTplBrief = `template parsing and building commands`
|
||||
cTplDc = `
|
||||
The "tpl" command is used for template parsing and building purpose.
|
||||
It can parse either template file or folder with multiple types of values support,
|
||||
like json/xml/yaml/toml/ini.
|
||||
`
|
||||
cTplParseBrief = `parse either template file or folder with multiple types of values`
|
||||
cTplParseEg = `
|
||||
gf tpl parse -p ./template -v values.json -r
|
||||
gf tpl parse -p ./template -v values.json -n *.tpl -r
|
||||
gf tpl parse -p ./template -v values.json -d '${{,}}' -r
|
||||
gf tpl parse -p ./template -v values.json -o ./template.parsed
|
||||
`
|
||||
cTplSupportValuesFilePattern = `*.json,*.xml,*.yaml,*.yml,*.toml,*.ini`
|
||||
)
|
||||
|
||||
type (
|
||||
cTplParseInput struct {
|
||||
g.Meta `name:"parse" config:"gfcli.tpl.parse" brief:"{cTplParseBrief}" eg:"{cTplParseEg}"`
|
||||
Path string `name:"path" short:"p" brief:"template file or folder path" v:"required"`
|
||||
Pattern string `name:"pattern" short:"n" brief:"template file pattern when path is a folder, default is:*" d:"*"`
|
||||
Recursive bool `name:"recursive" short:"c" brief:"recursively parsing files if path is folder, default is:true" d:"true"`
|
||||
Values string `name:"values" short:"v" brief:"template values file/folder, support file types like: json/xml/yaml/toml/ini" v:"required"`
|
||||
Output string `name:"output" short:"o" brief:"output file/folder path"`
|
||||
Delimiters string `name:"delimiters" short:"d" brief:"delimiters for template content parsing, default is:{{,}}" d:"{{,}}"`
|
||||
Replace bool `name:"replace" short:"r" brief:"replace original files" orphan:"true"`
|
||||
}
|
||||
cTplParseOutput struct{}
|
||||
)
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cTplBrief`: cTplBrief,
|
||||
`cTplDc`: cTplDc,
|
||||
`cTplParseEg`: cTplParseEg,
|
||||
`cTplParseBrief`: cTplParseBrief,
|
||||
})
|
||||
}
|
||||
|
||||
func (c *cTpl) Parse(ctx context.Context, in cTplParseInput) (out *cTplParseOutput, err error) {
|
||||
if in.Output == "" && !in.Replace {
|
||||
return nil, gerror.New(`parameter output and replace should not be both empty`)
|
||||
}
|
||||
delimiters := gstr.SplitAndTrim(in.Delimiters, ",")
|
||||
mlog.Debugf("delimiters input:%s, parsed:%#v", in.Delimiters, delimiters)
|
||||
if len(delimiters) != 2 {
|
||||
return nil, gerror.Newf(`invalid delimiters: %s`, in.Delimiters)
|
||||
}
|
||||
g.View().SetDelimiters(delimiters[0], delimiters[1])
|
||||
valuesMap, err := c.loadValues(ctx, in.Values)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if len(valuesMap) == 0 {
|
||||
return nil, gerror.Newf(`empty values loaded from values file/folder "%s"`, in.Values)
|
||||
}
|
||||
err = c.parsePath(ctx, valuesMap, in)
|
||||
if err == nil {
|
||||
mlog.Print("done!")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func (c *cTpl) parsePath(ctx context.Context, values g.Map, in cTplParseInput) (err error) {
|
||||
if !gfile.Exists(in.Path) {
|
||||
return gerror.Newf(`path "%s" does not exist`, in.Path)
|
||||
}
|
||||
var (
|
||||
path string
|
||||
files []string
|
||||
relativePath string
|
||||
outputPath string
|
||||
)
|
||||
path = gfile.RealPath(in.Path)
|
||||
if gfile.IsDir(path) {
|
||||
files, err = gfile.ScanDirFile(path, in.Pattern, in.Recursive)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
for _, file := range files {
|
||||
relativePath = gstr.Replace(file, path, "")
|
||||
if in.Output != "" {
|
||||
outputPath = gfile.Join(in.Output, relativePath)
|
||||
}
|
||||
if err = c.parseFile(ctx, file, outputPath, values, in); err != nil {
|
||||
return
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
if in.Output != "" {
|
||||
outputPath = in.Output
|
||||
}
|
||||
err = c.parseFile(ctx, path, outputPath, values, in)
|
||||
return
|
||||
}
|
||||
|
||||
func (c *cTpl) parseFile(ctx context.Context, file string, output string, values g.Map, in cTplParseInput) (err error) {
|
||||
output = gstr.ReplaceByMap(output, g.MapStrStr{
|
||||
`\\`: `\`,
|
||||
`//`: `/`,
|
||||
})
|
||||
content, err := g.View().Parse(ctx, file, values)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if output != "" {
|
||||
mlog.Printf(`parse file "%s" to "%s"`, file, output)
|
||||
return gfile.PutContents(output, content)
|
||||
}
|
||||
if in.Replace {
|
||||
mlog.Printf(`parse and replace file "%s"`, file)
|
||||
return gfile.PutContents(file, content)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (c *cTpl) loadValues(ctx context.Context, valuesPath string) (data g.Map, err error) {
|
||||
if !gfile.Exists(valuesPath) {
|
||||
return nil, gerror.Newf(`values file/folder "%s" does not exist`, valuesPath)
|
||||
}
|
||||
var j *gjson.Json
|
||||
if gfile.IsDir(valuesPath) {
|
||||
var valueFiles []string
|
||||
valueFiles, err = gfile.ScanDirFile(valuesPath, cTplSupportValuesFilePattern, true)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
data = make(g.Map)
|
||||
for _, file := range valueFiles {
|
||||
if j, err = gjson.Load(file); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
gutil.MapMerge(data, j.Map())
|
||||
}
|
||||
return
|
||||
}
|
||||
if j, err = gjson.Load(valuesPath); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
data = j.Map()
|
||||
return
|
||||
}
|
||||
279
cmd/gf/internal/cmd/cmd_up.go
Normal file
279
cmd/gf/internal/cmd/cmd_up.go
Normal file
@ -0,0 +1,279 @@
|
||||
// Copyright GoFrame gf Author(https://goframe.org). All Rights Reserved.
|
||||
//
|
||||
// This Source Code Form is subject to the terms of the MIT License.
|
||||
// If a copy of the MIT was not distributed with this file,
|
||||
// You can obtain one at https://github.com/gogf/gf.
|
||||
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"runtime"
|
||||
|
||||
"github.com/gogf/selfupdate"
|
||||
|
||||
"github.com/gogf/gf/v2/container/gset"
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"github.com/gogf/gf/v2/os/genv"
|
||||
"github.com/gogf/gf/v2/os/gfile"
|
||||
"github.com/gogf/gf/v2/os/gproc"
|
||||
"github.com/gogf/gf/v2/text/gstr"
|
||||
"github.com/gogf/gf/v2/util/gtag"
|
||||
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/mlog"
|
||||
"github.com/gogf/gf/cmd/gf/v2/internal/utility/utils"
|
||||
)
|
||||
|
||||
var (
|
||||
Up = cUp{}
|
||||
)
|
||||
|
||||
type cUp struct {
|
||||
g.Meta `name:"up" brief:"upgrade GoFrame version/tool to latest one in current project" eg:"{cUpEg}" `
|
||||
}
|
||||
|
||||
const (
|
||||
gfPackage = `github.com/gogf/gf/`
|
||||
cUpEg = `
|
||||
gf up
|
||||
gf up -a
|
||||
gf up -c
|
||||
gf up -cf
|
||||
gf up -a -m=install
|
||||
gf up -a -m=install -p=github.com/gogf/gf/cmd/gf/v2@latest
|
||||
`
|
||||
cliMethodHttpDownload = "http"
|
||||
cliMethodGoInstall = "install"
|
||||
)
|
||||
|
||||
func init() {
|
||||
gtag.Sets(g.MapStrStr{
|
||||
`cUpEg`: cUpEg,
|
||||
})
|
||||
}
|
||||
|
||||
type cUpInput struct {
|
||||
g.Meta `name:"up" config:"gfcli.up"`
|
||||
All bool `name:"all" short:"a" brief:"upgrade both version and cli, auto fix codes" orphan:"true"`
|
||||
Cli bool `name:"cli" short:"c" brief:"also upgrade CLI tool" orphan:"true"`
|
||||
Fix bool `name:"fix" short:"f" brief:"auto fix codes(it only make sense if cli is to be upgraded)" orphan:"true"`
|
||||
CliDownloadingMethod string `name:"cli-download-method" short:"m" brief:"cli upgrade method: http=download binary via HTTP GET, install=upgrade via go install" d:"http"`
|
||||
// CliModulePath specifies the module path for CLI installation via go install.
|
||||
// This is used when CliDownloadingMethod is set to "install".
|
||||
CliModulePath string `name:"cli-module-path" short:"p" brief:"custom cli module path for upgrade CLI tool with go install method" d:"github.com/gogf/gf/cmd/gf/v2@latest"`
|
||||
}
|
||||
|
||||
type cUpOutput struct{}
|
||||
|
||||
func (c cUp) Index(ctx context.Context, in cUpInput) (out *cUpOutput, err error) {
|
||||
defer func() {
|
||||
if err == nil {
|
||||
mlog.Print()
|
||||
mlog.Print(`👏congratulations! you've upgraded to the latest version of GoFrame! enjoy it!👏`)
|
||||
mlog.Print()
|
||||
}
|
||||
}()
|
||||
|
||||
var doUpgradeVersionOut *doUpgradeVersionOutput
|
||||
if in.All {
|
||||
in.Cli = true
|
||||
in.Fix = true
|
||||
}
|
||||
if doUpgradeVersionOut, err = c.doUpgradeVersion(ctx, in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if in.Cli {
|
||||
if err = c.doUpgradeCLI(ctx, in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
|
||||
if in.Cli && in.Fix {
|
||||
if doUpgradeVersionOut != nil && len(doUpgradeVersionOut.Items) > 0 {
|
||||
upgradedPathSet := gset.NewStrSet()
|
||||
for _, item := range doUpgradeVersionOut.Items {
|
||||
if !upgradedPathSet.AddIfNotExist(item.DirPath) {
|
||||
continue
|
||||
}
|
||||
if err = c.doAutoFixing(ctx, item.DirPath, item.Version); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
type doUpgradeVersionOutput struct {
|
||||
Items []doUpgradeVersionOutputItem
|
||||
}
|
||||
|
||||
type doUpgradeVersionOutputItem struct {
|
||||
DirPath string
|
||||
Version string
|
||||
}
|
||||
|
||||
func (c cUp) doUpgradeVersion(ctx context.Context, in cUpInput) (out *doUpgradeVersionOutput, err error) {
|
||||
mlog.Print(`start upgrading version...`)
|
||||
out = &doUpgradeVersionOutput{
|
||||
Items: make([]doUpgradeVersionOutputItem, 0),
|
||||
}
|
||||
type Package struct {
|
||||
Name string
|
||||
Version string
|
||||
}
|
||||
|
||||
var (
|
||||
temp string
|
||||
dirPath = gfile.Pwd()
|
||||
goModPath = gfile.Join(dirPath, "go.mod")
|
||||
)
|
||||
// It recursively upgrades the go.mod from sub folder to its parent folders.
|
||||
for {
|
||||
if gfile.Exists(goModPath) {
|
||||
var packages []Package
|
||||
err = gfile.ReadLines(goModPath, func(line string) error {
|
||||
line = gstr.Trim(line)
|
||||
line = gstr.TrimLeftStr(line, "require ")
|
||||
line = gstr.Trim(line)
|
||||
if gstr.HasPrefix(line, gfPackage) {
|
||||
array := gstr.SplitAndTrim(line, " ")
|
||||
packages = append(packages, Package{
|
||||
Name: array[0],
|
||||
Version: array[1],
|
||||
})
|
||||
}
|
||||
return nil
|
||||
})
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
for _, pkg := range packages {
|
||||
mlog.Printf(`upgrading "%s" from "%s" to "latest"`, pkg.Name, pkg.Version)
|
||||
mlog.Printf(`running command: go get %s@latest`, pkg.Name)
|
||||
// go get @latest
|
||||
command := fmt.Sprintf(`cd %s && go get %s@latest`, dirPath, pkg.Name)
|
||||
if err = gproc.ShellRun(ctx, command); err != nil {
|
||||
return
|
||||
}
|
||||
// go mod tidy
|
||||
if err = utils.GoModTidy(ctx, dirPath); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
out.Items = append(out.Items, doUpgradeVersionOutputItem{
|
||||
DirPath: dirPath,
|
||||
Version: pkg.Version,
|
||||
})
|
||||
}
|
||||
return
|
||||
}
|
||||
temp = gfile.Dir(dirPath)
|
||||
if temp == "" || temp == dirPath {
|
||||
return
|
||||
}
|
||||
dirPath = temp
|
||||
goModPath = gfile.Join(dirPath, "go.mod")
|
||||
}
|
||||
}
|
||||
|
||||
// doUpgradeCLI downloads the new version binary with process.
|
||||
func (c cUp) doUpgradeCLI(ctx context.Context, in cUpInput) (err error) {
|
||||
mlog.Print(`start upgrading cli...`)
|
||||
fmt.Println(` cli upgrade method:`, in.CliDownloadingMethod)
|
||||
switch in.CliDownloadingMethod {
|
||||
case cliMethodHttpDownload:
|
||||
return c.doUpgradeCLIWithHttpDownload(ctx)
|
||||
case cliMethodGoInstall:
|
||||
return c.doUpgradeCLIWithGoInstall(ctx, in)
|
||||
default:
|
||||
mlog.Fatalf(`invalid cli upgrade method: "%s", please use "http" or "install"`, in.CliDownloadingMethod)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func (c cUp) doUpgradeCLIWithHttpDownload(ctx context.Context) (err error) {
|
||||
mlog.Print(`start upgrading cli with http get download...`)
|
||||
var (
|
||||
downloadUrl = fmt.Sprintf(
|
||||
`https://github.com/gogf/gf/releases/latest/download/gf_%s_%s`,
|
||||
runtime.GOOS, runtime.GOARCH,
|
||||
)
|
||||
localSaveFilePath = gfile.SelfPath() + "~"
|
||||
)
|
||||
|
||||
if runtime.GOOS == "windows" {
|
||||
downloadUrl += ".exe"
|
||||
}
|
||||
|
||||
mlog.Printf(`start downloading "%s" to "%s", it may take some time`, downloadUrl, localSaveFilePath)
|
||||
err = utils.HTTPDownloadFileWithPercent(downloadUrl, localSaveFilePath)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
defer func() {
|
||||
mlog.Printf(`new version cli binary is successfully installed to "%s"`, gfile.SelfPath())
|
||||
mlog.Printf(`remove temporary buffer file "%s"`, localSaveFilePath)
|
||||
_ = gfile.RemoveFile(localSaveFilePath)
|
||||
}()
|
||||
|
||||
// It fails if file not exist or its size is less than 1MB.
|
||||
if !gfile.Exists(localSaveFilePath) || gfile.Size(localSaveFilePath) < 1024*1024 {
|
||||
mlog.Fatalf(`download "%s" to "%s" failed`, downloadUrl, localSaveFilePath)
|
||||
}
|
||||
|
||||
newFile, err := gfile.Open(localSaveFilePath)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
// selfupdate
|
||||
err = selfupdate.Apply(newFile, selfupdate.Options{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func (c cUp) doUpgradeCLIWithGoInstall(ctx context.Context, in cUpInput) (err error) {
|
||||
mlog.Print(`upgrading cli with go install...`)
|
||||
if !genv.Contains("GOPATH") {
|
||||
mlog.Fatal(`"GOPATH" environment variable does not exist, please check your go installation`)
|
||||
}
|
||||
|
||||
command := fmt.Sprintf(`go install %s`, in.CliModulePath)
|
||||
mlog.Printf(`running command: %s`, command)
|
||||
err = gproc.ShellRun(ctx, command)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
cliFilePath := gfile.Join(genv.Get("GOPATH").String(), "bin/gf")
|
||||
if runtime.GOOS == "windows" {
|
||||
cliFilePath += ".exe"
|
||||
}
|
||||
|
||||
// It fails if file not exist or its size is less than 1MB.
|
||||
if !gfile.Exists(cliFilePath) || gfile.Size(cliFilePath) < 1024*1024 {
|
||||
mlog.Fatalf(`go install %s failed, "%s" does not exist or its size is less than 1MB`, in.CliModulePath, cliFilePath)
|
||||
}
|
||||
|
||||
newFile, err := gfile.Open(cliFilePath)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
// selfupdate
|
||||
err = selfupdate.Apply(newFile, selfupdate.Options{})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
func (c cUp) doAutoFixing(ctx context.Context, dirPath string, version string) (err error) {
|
||||
mlog.Printf(`auto fixing directory path "%s" from version "%s" ...`, dirPath, version)
|
||||
command := fmt.Sprintf(`gf fix -p %s`, dirPath)
|
||||
_ = gproc.ShellRun(ctx, command)
|
||||
return
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user