tasks.json 8.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326
  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. "AF: Generate Svg Files"
  25. ],
  26. "presentation": {
  27. "reveal": "always",
  28. "panel": "new"
  29. }
  30. },
  31. {
  32. "label": "AF: Clean + Rebuild All (iOS)",
  33. "type": "shell",
  34. "dependsOrder": "sequence",
  35. "dependsOn": [
  36. "AF: Dart Clean",
  37. "AF: Flutter Clean",
  38. "AF: Build Appflowy Core For iOS",
  39. "AF: Flutter Pub Get",
  40. "AF: Flutter Package Get",
  41. "AF: Generate Language Files",
  42. "AF: Generate Freezed Files",
  43. "AF: Generate Svg Files"
  44. ],
  45. "presentation": {
  46. "reveal": "always",
  47. "panel": "new"
  48. }
  49. },
  50. {
  51. "label": "AF: Clean + Rebuild All (iOS Simulator)",
  52. "type": "shell",
  53. "dependsOrder": "sequence",
  54. "dependsOn": [
  55. "AF: Dart Clean",
  56. "AF: Flutter Clean",
  57. "AF: Build Appflowy Core For iOS Simulator",
  58. "AF: Flutter Pub Get",
  59. "AF: Flutter Package Get",
  60. "AF: Generate Language Files",
  61. "AF: Generate Freezed Files",
  62. "AF: Generate Svg Files"
  63. ],
  64. "presentation": {
  65. "reveal": "always",
  66. "panel": "new"
  67. }
  68. },
  69. {
  70. "label": "AF: Build Appflowy Core For iOS",
  71. "type": "shell",
  72. "command": "cargo make --profile development-ios-arm64 appflowy-core-dev-ios",
  73. "group": "build",
  74. "options": {
  75. "cwd": "${workspaceFolder}"
  76. }
  77. },
  78. {
  79. "label": "AF: Build Appflowy Core For iOS Simulator",
  80. "type": "shell",
  81. "command": "cargo make --profile development-ios-arm64-sim appflowy-core-dev-ios",
  82. "group": "build",
  83. "options": {
  84. "cwd": "${workspaceFolder}"
  85. }
  86. },
  87. {
  88. "label": "AF: Clean + Rebuild All (Android)",
  89. "type": "shell",
  90. "dependsOrder": "sequence",
  91. "dependsOn": [
  92. "AF: Dart Clean",
  93. "AF: Flutter Clean",
  94. "AF: Build Appflowy Core For Android",
  95. "AF: Flutter Pub Get",
  96. "AF: Flutter Package Get",
  97. "AF: Generate Language Files",
  98. "AF: Generate Freezed Files",
  99. "AF: Generate Svg Files"
  100. ],
  101. "presentation": {
  102. "reveal": "always",
  103. "panel": "new"
  104. }
  105. },
  106. {
  107. "label": "AF: Build Appflowy Core For Android",
  108. "type": "shell",
  109. "command": "cargo make --profile development-android appflowy-core-dev-android",
  110. "group": "build",
  111. "options": {
  112. "cwd": "${workspaceFolder}"
  113. }
  114. },
  115. {
  116. "label": "AF: Build Appflowy Core",
  117. "type": "shell",
  118. "windows": {
  119. "command": "cargo make --profile development-windows-x86 appflowy-core-dev"
  120. },
  121. "linux": {
  122. "command": "cargo make --profile \"development-linux-$(uname -m)\" appflowy-core-dev"
  123. },
  124. "osx": {
  125. "command": "cargo make --profile \"development-mac-$(uname -m)\" appflowy-core-dev"
  126. },
  127. "group": "build",
  128. "options": {
  129. "cwd": "${workspaceFolder}"
  130. }
  131. },
  132. {
  133. "label": "AF: Code Gen",
  134. "type": "shell",
  135. "dependsOrder": "sequence",
  136. "dependsOn": [
  137. "AF: Flutter Clean",
  138. "AF: Flutter Pub Get",
  139. "AF: Flutter Package Get",
  140. "AF: Generate Language Files",
  141. "AF: Generate Freezed Files",
  142. "AF: Generate Svg Files"
  143. ],
  144. "group": {
  145. "kind": "build",
  146. "isDefault": true
  147. },
  148. "presentation": {
  149. "reveal": "always",
  150. "panel": "new"
  151. }
  152. },
  153. {
  154. "label": "AF: Flutter Clean",
  155. "type": "shell",
  156. "command": "flutter clean",
  157. "options": {
  158. "cwd": "${workspaceFolder}/appflowy_flutter"
  159. }
  160. },
  161. {
  162. "label": "AF: Flutter Pub Get",
  163. "type": "shell",
  164. "command": "flutter pub get",
  165. "options": {
  166. "cwd": "${workspaceFolder}/appflowy_flutter"
  167. }
  168. },
  169. {
  170. "label": "AF: Flutter Package Get",
  171. "type": "shell",
  172. "command": "flutter packages pub get",
  173. "options": {
  174. "cwd": "${workspaceFolder}/appflowy_flutter"
  175. }
  176. },
  177. {
  178. "label": "AF: Generate Freezed Files",
  179. "type": "shell",
  180. "command": "sh ./scripts/code_generation/freezed/generate_freezed.sh",
  181. "options": {
  182. "cwd": "${workspaceFolder}"
  183. },
  184. "group": "build",
  185. "windows": {
  186. "options": {
  187. "shell": {
  188. "executable": "cmd.exe",
  189. "args": [
  190. "/d",
  191. "/c",
  192. ".\\scripts\\code_generation\\freezed\\generate_freezed.cmd"
  193. ]
  194. }
  195. }
  196. }
  197. },
  198. {
  199. "label": "AF: Generate Language Files",
  200. "type": "shell",
  201. "command": "sh ./scripts/code_generation/language_files/generate_language_files.sh",
  202. "windows": {
  203. "options": {
  204. "shell": {
  205. "executable": "cmd.exe",
  206. "args": [
  207. "/d",
  208. "/c",
  209. ".\\scripts\\code_generation\\language_files\\generate_language_files.cmd"
  210. ]
  211. }
  212. }
  213. },
  214. "group": "build",
  215. "options": {
  216. "cwd": "${workspaceFolder}"
  217. }
  218. },
  219. {
  220. "label": "AF: Generate Svg Files",
  221. "type": "shell",
  222. "command": "sh ./scripts/code_generation/flowy_icons/generate_flowy_icons.sh",
  223. "windows": {
  224. "options": {
  225. "shell": {
  226. "executable": "cmd.exe",
  227. "args": [
  228. "/d",
  229. "/c",
  230. ".\\scripts\\code_generation\\flowy_icons\\generate_flowy_icons.cmd"
  231. ]
  232. }
  233. }
  234. },
  235. "group": "build",
  236. "options": {
  237. "cwd": "${workspaceFolder}"
  238. }
  239. },
  240. {
  241. "label": "AF: Flutter Clean",
  242. "type": "shell",
  243. "command": "cargo make flutter_clean",
  244. "group": "build",
  245. "options": {
  246. "cwd": "${workspaceFolder}"
  247. }
  248. },
  249. {
  250. "label": "AF: flutter build aar",
  251. "type": "flutter",
  252. "command": "flutter",
  253. "args": ["build", "aar"],
  254. "group": "build",
  255. "problemMatcher": [],
  256. "detail": "appflowy_flutter"
  257. },
  258. {
  259. "label": "AF: Tauri UI Dev",
  260. "type": "shell",
  261. "isBackground": true,
  262. "command": "yarn",
  263. "args": ["dev"],
  264. "options": {
  265. "cwd": "${workspaceFolder}/appflowy_tauri"
  266. }
  267. },
  268. {
  269. "label": "AF: Tauri UI Build",
  270. "type": "shell",
  271. "command": "pnpm run build",
  272. "options": {
  273. "cwd": "${workspaceFolder}/appflowy_tauri"
  274. }
  275. },
  276. {
  277. "label": "AF: Tauri Dev",
  278. "type": "shell",
  279. "command": "npm run tauri:dev",
  280. "options": {
  281. "cwd": "${workspaceFolder}/appflowy_tauri"
  282. }
  283. },
  284. {
  285. "label": "AF: Tauri Clean",
  286. "type": "shell",
  287. "command": "cargo make tauri_clean",
  288. "options": {
  289. "cwd": "${workspaceFolder}"
  290. }
  291. },
  292. {
  293. "label": "AF: Tauri Clean + Dev",
  294. "type": "shell",
  295. "dependsOrder": "sequence",
  296. "dependsOn": ["AF: Tauri Clean", "AF: Tauri UI Dev"],
  297. "options": {
  298. "cwd": "${workspaceFolder}"
  299. }
  300. },
  301. {
  302. "label": "AF: Tauri ESLint",
  303. "type": "shell",
  304. "command": "npx eslint --fix src",
  305. "options": {
  306. "cwd": "${workspaceFolder}/appflowy_tauri"
  307. }
  308. },
  309. {
  310. "label": "AF: Generate Env File",
  311. "type": "shell",
  312. "command": "dart run build_runner clean && dart run build_runner build --delete-conflicting-outputs ",
  313. "options": {
  314. "cwd": "${workspaceFolder}/appflowy_flutter"
  315. }
  316. },
  317. {
  318. "label": "AF: Generate AppFlowyEnv",
  319. "type": "shell",
  320. "command": "dart run build_runner build --delete-conflicting-outputs",
  321. "options": {
  322. "cwd": "${workspaceFolder}/appflowy_flutter/packages/appflowy_backend"
  323. }
  324. }
  325. ]
  326. }