tasks.json 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246
  1. {
  2. "version": "2.0.0",
  3. // https://code.visualstudio.com/docs/editor/tasks
  4. // https://gist.github.com/deadalusai/9e13e36d61ec7fb72148
  5. // ${workspaceRoot}: the root folder of the team
  6. // ${file}: the current opened file
  7. // ${fileBasename}: the current opened file's basename
  8. // ${fileDirname}: the current opened file's dirname
  9. // ${fileExtname}: the current opened file's extension
  10. // ${cwd}: the current working directory of the spawned process
  11. "tasks": [
  12. {
  13. "label": "AF: Clean + Rebuild All",
  14. "type": "shell",
  15. "dependsOrder": "sequence",
  16. "dependsOn": [
  17. "AF: Dart Clean",
  18. "AF: Flutter Clean",
  19. "AF: Build Appflowy Core",
  20. "AF: Flutter Pub Get",
  21. "AF: Flutter Package Get",
  22. "AF: Generate Language Files",
  23. "AF: Generate Freezed Files"
  24. ],
  25. "presentation": {
  26. "reveal": "always",
  27. "panel": "new"
  28. }
  29. },
  30. {
  31. "label": "AF: Clean + Rebuild All (Android)",
  32. "type": "shell",
  33. "dependsOrder": "sequence",
  34. "dependsOn": [
  35. "AF: Dart Clean",
  36. "AF: Flutter Clean",
  37. "AF: Build Appflowy Core_for_android",
  38. "AF: Flutter Pub Get",
  39. "AF: Flutter Package Get",
  40. "AF: Generate Language Files",
  41. "AF: Generate Freezed Files"
  42. ],
  43. "presentation": {
  44. "reveal": "always",
  45. "panel": "new"
  46. }
  47. },
  48. {
  49. "label": "AF: Build Appflowy Core_for_android",
  50. "type": "shell",
  51. "command": "cargo make --profile development-android appflowy-core-dev-android",
  52. "group": "build",
  53. "options": {
  54. "cwd": "${workspaceFolder}"
  55. }
  56. },
  57. {
  58. "label": "AF: Build Appflowy Core",
  59. "type": "shell",
  60. "windows": {
  61. "command": "cargo make --profile development-windows-x86 appflowy-core-dev"
  62. },
  63. "linux": {
  64. "command": "cargo make --profile \"development-linux-$(uname -m)\" appflowy-core-dev"
  65. },
  66. "osx": {
  67. "command": "cargo make --profile \"development-mac-$(uname -m)\" appflowy-core-dev"
  68. },
  69. "group": "build",
  70. "options": {
  71. "cwd": "${workspaceFolder}"
  72. }
  73. },
  74. {
  75. "label": "AF: Code Gen",
  76. "type": "shell",
  77. "dependsOrder": "sequence",
  78. "dependsOn": [
  79. "AF: Flutter Clean",
  80. "AF: Flutter Pub Get",
  81. "AF: Flutter Package Get",
  82. "AF: Generate Language Files",
  83. "AF: Generate Freezed Files"
  84. ],
  85. "group": {
  86. "kind": "build",
  87. "isDefault": true
  88. },
  89. "presentation": {
  90. "reveal": "always",
  91. "panel": "new"
  92. }
  93. },
  94. {
  95. "label": "AF: Flutter Clean",
  96. "type": "shell",
  97. "command": "flutter clean",
  98. "options": {
  99. "cwd": "${workspaceFolder}/appflowy_flutter"
  100. }
  101. },
  102. {
  103. "label": "AF: Flutter Pub Get",
  104. "type": "shell",
  105. "command": "flutter pub get",
  106. "options": {
  107. "cwd": "${workspaceFolder}/appflowy_flutter"
  108. }
  109. },
  110. {
  111. "label": "AF: Flutter Package Get",
  112. "type": "shell",
  113. "command": "flutter packages pub get",
  114. "options": {
  115. "cwd": "${workspaceFolder}/appflowy_flutter"
  116. }
  117. },
  118. {
  119. "label": "AF: Generate Freezed Files",
  120. "type": "shell",
  121. "command": "sh ./scripts/code_generation/freezed/generate_freezed.sh",
  122. "options": {
  123. "cwd": "${workspaceFolder}"
  124. },
  125. "group": "build",
  126. "windows": {
  127. "options": {
  128. "shell": {
  129. "executable": "cmd.exe",
  130. "args": [
  131. "/d",
  132. "/c",
  133. ".\\scripts\\code_generation\\freezed\\generate_freezed.cmd"
  134. ]
  135. }
  136. }
  137. },
  138. },
  139. {
  140. "label": "AF: Generate Language Files",
  141. "type": "shell",
  142. "command": "sh ./scripts/code_generation/language_files/generate_language_files.sh",
  143. "windows": {
  144. "options": {
  145. "shell": {
  146. "executable": "cmd.exe",
  147. "args": [
  148. "/d",
  149. "/c",
  150. ".\\scripts\\code_generation\\language_files\\generate_language_files.cmd"
  151. ]
  152. }
  153. }
  154. },
  155. "group": "build",
  156. "options": {
  157. "cwd": "${workspaceFolder}"
  158. }
  159. },
  160. {
  161. "label": "AF: Flutter Clean",
  162. "type": "shell",
  163. "command": "cargo make flutter_clean",
  164. "group": "build",
  165. "options": {
  166. "cwd": "${workspaceFolder}"
  167. }
  168. },
  169. {
  170. "label": "AF: flutter build aar",
  171. "type": "flutter",
  172. "command": "flutter",
  173. "args": [
  174. "build",
  175. "aar"
  176. ],
  177. "group": "build",
  178. "problemMatcher": [],
  179. "detail": "appflowy_flutter"
  180. },
  181. {
  182. "label": "AF: Tauri UI Dev",
  183. "type": "shell",
  184. "isBackground": true,
  185. "command": "yarn",
  186. "args": [
  187. "dev"
  188. ],
  189. "options": {
  190. "cwd": "${workspaceFolder}/appflowy_tauri"
  191. }
  192. },
  193. {
  194. "label": "AF: Tauri UI Build",
  195. "type": "shell",
  196. "command": "pnpm run build",
  197. "options": {
  198. "cwd": "${workspaceFolder}/appflowy_tauri"
  199. }
  200. },
  201. {
  202. "label": "AF: Tauri Dev",
  203. "type": "shell",
  204. "command": "npm run tauri:dev",
  205. "options": {
  206. "cwd": "${workspaceFolder}/appflowy_tauri"
  207. }
  208. },
  209. {
  210. "label": "AF: Tauri Clean",
  211. "type": "shell",
  212. "command": "cargo make tauri_clean",
  213. "options": {
  214. "cwd": "${workspaceFolder}"
  215. }
  216. },
  217. {
  218. "label": "AF: Tauri Clean + Dev",
  219. "type": "shell",
  220. "dependsOrder": "sequence",
  221. "dependsOn": [
  222. "AF: Tauri Clean",
  223. "AF: Tauri UI Dev"
  224. ],
  225. "options": {
  226. "cwd": "${workspaceFolder}"
  227. }
  228. },
  229. {
  230. "label": "AF: Tauri ESLint",
  231. "type": "shell",
  232. "command": "npx eslint --fix src",
  233. "options": {
  234. "cwd": "${workspaceFolder}/appflowy_tauri"
  235. }
  236. },
  237. {
  238. "label": "AF: Generate Env",
  239. "type": "shell",
  240. "command": "dart run build_runner clean && dart run build_runner build --delete-conflicting-outputs ",
  241. "options": {
  242. "cwd": "${workspaceFolder}/appflowy_flutter"
  243. }
  244. },
  245. ]
  246. }