3:I[9275,[],""] 5:I[1343,[],""] 6:I[8700,["231","static/chunks/231-42eeaa612179830e.js","837","static/chunks/837-29ccadcc1eaf8d5e.js","185","static/chunks/app/layout-4689815b234f48f7.js"],"ThemeProviders"] 7:I[4080,["231","static/chunks/231-42eeaa612179830e.js","837","static/chunks/837-29ccadcc1eaf8d5e.js","185","static/chunks/app/layout-4689815b234f48f7.js"],""] 8:I[9032,["231","static/chunks/231-42eeaa612179830e.js","837","static/chunks/837-29ccadcc1eaf8d5e.js","185","static/chunks/app/layout-4689815b234f48f7.js"],"KBarSearchProvider"] 9:I[231,["231","static/chunks/231-42eeaa612179830e.js","173","static/chunks/173-af5b99c330035292.js","797","static/chunks/app/blog/%5B...slug%5D/page-c1896e7910e189aa.js"],""] a:I[509,["231","static/chunks/231-42eeaa612179830e.js","837","static/chunks/837-29ccadcc1eaf8d5e.js","185","static/chunks/app/layout-4689815b234f48f7.js"],"KBarButton"] b:I[1398,["231","static/chunks/231-42eeaa612179830e.js","837","static/chunks/837-29ccadcc1eaf8d5e.js","185","static/chunks/app/layout-4689815b234f48f7.js"],"default"] c:I[8976,["231","static/chunks/231-42eeaa612179830e.js","837","static/chunks/837-29ccadcc1eaf8d5e.js","185","static/chunks/app/layout-4689815b234f48f7.js"],"default"] 4:["slug","git-flow","c"] 0:["X5bocbsvtsRLAPTmoOG9E",[[["",{"children":["blog",{"children":[["slug","git-flow","c"],{"children":["__PAGE__?{\"slug\":[\"git-flow\"]}",{}]}]}]},"$undefined","$undefined",true],["",{"children":["blog",{"children":[["slug","git-flow","c"],{"children":["__PAGE__",{},[["$L1","$L2"],null],null]},["$","$L3",null,{"parallelRouterKey":"children","segmentPath":["children","blog","children","$4","children"],"error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","notFoundStyles":"$undefined","styles":[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/8666460c05bbe3a0.css","precedence":"next","crossOrigin":"$undefined"}]]}],null]},["$","$L3",null,{"parallelRouterKey":"children","segmentPath":["children","blog","children"],"error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":"$undefined","notFoundStyles":"$undefined","styles":null}],null]},[["$","html",null,{"lang":"vi-VN","className":"__variable_587f35 scroll-smooth","suppressHydrationWarning":true,"children":[["$","link",null,{"rel":"manifest","href":"/static/favicons/site.webmanifest"}],["$","link",null,{"rel":"icon","type":"image/png","sizes":"32x32","href":"/static/favicons/favicon.png"}],["$","meta",null,{"name":"msapplication-TileColor","content":"#000000"}],["$","meta",null,{"name":"theme-color","media":"(prefers-color-scheme: light)","content":"#fff"}],["$","meta",null,{"name":"theme-color","media":"(prefers-color-scheme: dark)","content":"#000"}],["$","link",null,{"rel":"alternate","type":"application/rss+xml","href":"/feed.xml"}],["$","body",null,{"className":"bg-white pl-[calc(100vw-100%)] text-black antialiased dark:bg-gray-950 dark:text-white","children":["$","$L6",null,{"children":[["$undefined","$undefined","$undefined",["$","$L7",null,{"async":true,"defer":true,"data-website-id":"$undefined","src":"https://analytics.umami.is/script.js"}],"$undefined","$undefined"],["$","section",null,{"className":"mx-auto max-w-3xl px-4 sm:px-6 xl:max-w-5xl xl:px-0","children":[["$","$L8",null,{"kbarConfig":{"searchDocumentsPath":"/search.json"},"children":[["$","header",null,{"className":"flex items-center w-full bg-white dark:bg-gray-950 justify-between py-10","children":[["$","$L9",null,{"className":"break-words","href":"/","aria-label":"ducdh.com","children":["$","div",null,{"className":"flex items-center justify-between","children":[["$","div",null,{"className":"mr-3","children":["$","svg",null,{"xmlns":"http://www.w3.org/2000/svg","width":26,"height":26,"fill":"currentColor","className":"logo_svg__bi logo_svg__bi-boxes logo_svg__mb-1","viewBox":"0 0 16 16","children":["$","path",null,{"d":"M7.752.066a.5.5 0 0 1 .496 0l3.75 2.143a.5.5 0 0 1 .252.434v3.995l3.498 2A.5.5 0 0 1 16 9.07v4.286a.5.5 0 0 1-.252.434l-3.75 2.143a.5.5 0 0 1-.496 0l-3.502-2-3.502 2.001a.5.5 0 0 1-.496 0l-3.75-2.143A.5.5 0 0 1 0 13.357V9.071a.5.5 0 0 1 .252-.434L3.75 6.638V2.643a.5.5 0 0 1 .252-.434zM4.25 7.504 1.508 9.071l2.742 1.567 2.742-1.567zM7.5 9.933l-2.75 1.571v3.134l2.75-1.571zm1 3.134 2.75 1.571v-3.134L8.5 9.933zm.508-3.996 2.742 1.567 2.742-1.567-2.742-1.567zm2.242-2.433V3.504L8.5 5.076V8.21zM7.5 8.21V5.076L4.75 3.504v3.134zM5.258 2.643 8 4.21l2.742-1.567L8 1.076zM15 9.933l-2.75 1.571v3.134L15 13.067zM3.75 14.638v-3.134L1 9.933v3.134z"}]}]}],["$","div",null,{"className":"hidden h-6 text-2xl font-semibold sm:block","children":"ducdh.com"}]]}]}],["$","div",null,{"className":"flex items-center space-x-4 leading-5 sm:space-x-6","children":[["$","div",null,{"className":"no-scrollbar hidden max-w-40 items-center space-x-4 overflow-x-auto sm:flex sm:space-x-6 md:max-w-72 lg:max-w-96","children":[["$","$L9",null,{"className":"block font-medium text-gray-900 hover:text-primary-500 dark:text-gray-100 dark:hover:text-primary-400","href":"/blog","children":"Blog"}],["$","$L9",null,{"className":"block font-medium text-gray-900 hover:text-primary-500 dark:text-gray-100 dark:hover:text-primary-400","href":"/tags","children":"Tags"}],["$","$L9",null,{"className":"block font-medium text-gray-900 hover:text-primary-500 dark:text-gray-100 dark:hover:text-primary-400","href":"/about","children":"About"}]]}],["$","$La",null,{"aria-label":"Search","children":["$","svg",null,{"xmlns":"http://www.w3.org/2000/svg","fill":"none","viewBox":"0 0 24 24","strokeWidth":1.5,"stroke":"currentColor","className":"h-6 w-6 text-gray-900 hover:text-primary-500 dark:text-gray-100 dark:hover:text-primary-400","children":["$","path",null,{"strokeLinecap":"round","strokeLinejoin":"round","d":"M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607z"}]}]}],["$","$Lb",null,{}],["$","$Lc",null,{}]]}]]}],["$","main",null,{"className":"mb-auto","children":["$","$L3",null,{"parallelRouterKey":"children","segmentPath":["children"],"error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L5",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":["$","div",null,{"className":"flex flex-col items-start justify-start md:mt-24 md:flex-row md:items-center md:justify-center md:space-x-6","children":[["$","div",null,{"className":"space-x-2 pb-8 pt-6 md:space-y-5","children":["$","h1",null,{"className":"text-6xl font-extrabold leading-9 tracking-tight text-gray-900 dark:text-gray-100 md:border-r-2 md:px-6 md:text-8xl md:leading-14","children":"404"}]}],["$","div",null,{"className":"max-w-md","children":[["$","p",null,{"className":"mb-4 text-xl font-bold leading-normal md:text-2xl","children":"Sorry we couldn't find this page."}],["$","p",null,{"className":"mb-8","children":"But dont worry, you can find plenty of other things on our homepage."}],["$","$L9",null,{"className":"focus:shadow-outline-blue inline rounded-lg border border-transparent bg-blue-600 px-4 py-2 text-sm font-medium leading-5 text-white shadow transition-colors duration-150 hover:bg-blue-700 focus:outline-none dark:hover:bg-blue-500","href":"/","children":"Back to homepage"}]]}]]}],"notFoundStyles":[],"styles":null}]}]]}],["$","footer",null,{"children":["$","div",null,{"className":"mt-16 flex flex-col items-center","children":[["$","div",null,{"className":"mb-3 flex space-x-4","children":[["$","a",null,{"className":"text-sm text-gray-500 transition hover:text-gray-600","target":"_blank","rel":"noopener noreferrer","href":"mailto:huuduc.uneti@gmail.com","children":[["$","span",null,{"className":"sr-only","children":"mail"}],["$","svg",null,{"xmlns":"http://www.w3.org/2000/svg","viewBox":"0 0 20 20","className":"fill-current text-gray-700 hover:text-primary-500 dark:text-gray-200 dark:hover:text-primary-400 h-6 w-6","children":[["$","title",null,{"children":"Mail"}],["$","path",null,{"d":"M2.003 5.884L10 9.882l7.997-3.998A2 2 0 0016 4H4a2 2 0 00-1.997 1.884z"}],["$","path",null,{"d":"M18 8.118l-8 4-8-4V14a2 2 0 002 2h12a2 2 0 002-2V8.118z"}]]}]]}],["$","a",null,{"className":"text-sm text-gray-500 transition hover:text-gray-600","target":"_blank","rel":"noopener noreferrer","href":"https://github.com/dhduc","children":[["$","span",null,{"className":"sr-only","children":"github"}],["$","svg",null,{"xmlns":"http://www.w3.org/2000/svg","viewBox":"0 0 24 24","className":"fill-current text-gray-700 hover:text-primary-500 dark:text-gray-200 dark:hover:text-primary-400 h-6 w-6","children":[["$","title",null,{"children":"GitHub"}],["$","path",null,{"d":"M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"}]]}]]}],["$","a",null,{"className":"text-sm text-gray-500 transition hover:text-gray-600","target":"_blank","rel":"noopener noreferrer","href":"https://facebook.com/huuduc.a7","children":[["$","span",null,{"className":"sr-only","children":"facebook"}],["$","svg",null,{"xmlns":"http://www.w3.org/2000/svg","viewBox":"0 0 24 24","className":"fill-current text-gray-700 hover:text-primary-500 dark:text-gray-200 dark:hover:text-primary-400 h-6 w-6","children":[["$","title",null,{"children":"Facebook"}],["$","path",null,{"d":"M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z"}]]}]]}],null,["$","a",null,{"className":"text-sm text-gray-500 transition hover:text-gray-600","target":"_blank","rel":"noopener noreferrer","href":"https://www.linkedin.com/in/ducdh","children":[["$","span",null,{"className":"sr-only","children":"linkedin"}],["$","svg",null,{"xmlns":"http://www.w3.org/2000/svg","viewBox":"0 0 24 24","className":"fill-current text-gray-700 hover:text-primary-500 dark:text-gray-200 dark:hover:text-primary-400 h-6 w-6","children":[["$","title",null,{"children":"Linkedin"}],["$","path",null,{"d":"M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433a2.062 2.062 0 01-2.063-2.065 2.064 2.064 0 112.063 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z"}]]}]]}],null,["$","a",null,{"className":"text-sm text-gray-500 transition hover:text-gray-600","target":"_blank","rel":"noopener noreferrer","href":"https://twitter.com/_ducdh","children":[["$","span",null,{"className":"sr-only","children":"x"}],["$","svg",null,{"xmlns":"http://www.w3.org/2000/svg","viewBox":"0 0 24 24","className":"fill-current text-gray-700 hover:text-primary-500 dark:text-gray-200 dark:hover:text-primary-400 h-6 w-6","children":[["$","title",null,{"children":"X"}],["$","path",null,{"d":"M18.901 1.153h3.68l-8.04 9.19L24 22.846h-7.406l-5.8-7.584-6.638 7.584H.474l8.6-9.83L0 1.154h7.594l5.243 6.932ZM17.61 20.644h2.039L6.486 3.24H4.298Z"}]]}]]}],null,null]}],["$","div",null,{"className":"mb-2 flex space-x-2 text-sm text-gray-500 dark:text-gray-400","children":[["$","div",null,{"children":"Duc Dao"}],["$","div",null,{"children":" • "}],["$","div",null,{"children":"© 2024"}],["$","div",null,{"children":" • "}],["$","$L9",null,{"className":"break-words","href":"/","children":"Homepage | ducdh.com"}]]}]]}]}]]}]]}]}]]}],null],null],[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/12667d03f03df565.css","precedence":"next","crossOrigin":"$undefined"}],["$","link","1",{"rel":"stylesheet","href":"/_next/static/css/68d903e7b242758d.css","precedence":"next","crossOrigin":"$undefined"}]],"$Ld"]]]] e:I[4347,["231","static/chunks/231-42eeaa612179830e.js","173","static/chunks/173-af5b99c330035292.js","797","static/chunks/app/blog/%5B...slug%5D/page-c1896e7910e189aa.js"],"default"] f:I[8173,["231","static/chunks/231-42eeaa612179830e.js","173","static/chunks/173-af5b99c330035292.js","797","static/chunks/app/blog/%5B...slug%5D/page-c1896e7910e189aa.js"],"Image"] 10:I[9629,["231","static/chunks/231-42eeaa612179830e.js","173","static/chunks/173-af5b99c330035292.js","797","static/chunks/app/blog/%5B...slug%5D/page-c1896e7910e189aa.js"],"default"] 2:[["$","script",null,{"type":"application/ld+json","dangerouslySetInnerHTML":{"__html":"{\"@context\":\"https://schema.org\",\"@type\":\"BlogPosting\",\"headline\":\"Git Convention and Git Flow Cơ Bản và Nâng Cao\",\"datePublished\":\"2023-06-09T00:00:00.000Z\",\"dateModified\":\"2023-06-09T00:00:00.000Z\",\"description\":\"Git Convention and Git Flow Cơ Bản và Nâng Cao\",\"image\":\"\",\"url\":\"https://ducdh.com/blog/git-flow\",\"author\":[{\"@type\":\"Person\",\"name\":\"Duc Dao\"}]}"}}],["$","section",null,{"className":"mx-auto max-w-3xl px-4 sm:px-6 xl:max-w-5xl xl:px-0","children":[["$","$Le",null,{}],["$","article",null,{"children":["$","div",null,{"className":"xl:divide-y xl:divide-gray-200 xl:dark:divide-gray-700","children":[["$","header",null,{"className":"pt-6 xl:pb-6","children":["$","div",null,{"className":"space-y-1 text-center","children":[["$","dl",null,{"className":"space-y-10","children":["$","div",null,{"children":[["$","dt",null,{"className":"sr-only","children":"Published on"}],["$","dd",null,{"className":"text-base font-medium leading-6 text-gray-500 dark:text-gray-400","children":["$","time",null,{"dateTime":"2023-06-09T00:00:00.000Z","children":"Thứ Sáu, 9 tháng 6, 2023"}]}]]}]}],["$","div",null,{"children":["$","h1",null,{"className":"text-3xl font-extrabold leading-9 tracking-tight text-gray-900 dark:text-gray-100 sm:text-4xl sm:leading-10 md:text-5xl md:leading-14","children":"Git Convention and Git Flow Cơ Bản và Nâng Cao"}]}]]}]}],["$","div",null,{"className":"grid-rows-[auto_1fr] divide-y divide-gray-200 pb-8 dark:divide-gray-700 xl:grid xl:grid-cols-4 xl:gap-x-6 xl:divide-y-0","children":[["$","dl",null,{"className":"pb-10 pt-6 xl:border-b xl:border-gray-200 xl:pt-11 xl:dark:border-gray-700","children":[["$","dt",null,{"className":"sr-only","children":"Authors"}],["$","dd",null,{"children":["$","ul",null,{"className":"flex flex-wrap justify-center gap-4 sm:space-x-12 xl:block xl:space-x-0 xl:space-y-8","children":[["$","li","Duc Dao",{"className":"flex items-center space-x-2","children":[["$","$Lf",null,{"src":"/static/images/avatar.jpg","width":38,"height":38,"alt":"avatar","className":"h-10 w-10 rounded-full"}],["$","dl",null,{"className":"whitespace-nowrap text-sm font-medium leading-5","children":[["$","dt",null,{"className":"sr-only","children":"Name"}],["$","dd",null,{"className":"text-gray-900 dark:text-gray-100","children":"Duc Dao"}],["$","dt",null,{"className":"sr-only","children":"Twitter"}],["$","dd",null,{"children":["$","a",null,{"className":"text-primary-500 hover:text-primary-600 dark:hover:text-primary-400","target":"_blank","rel":"noopener noreferrer","href":"https://twitter.com/_ducdh","children":"@_ducdh"}]}]]}]]}]]}]}]]}],["$","div",null,{"className":"divide-y divide-gray-200 dark:divide-gray-700 xl:col-span-3 xl:row-span-2 xl:pb-0","children":[["$","div",null,{"className":"prose max-w-none pb-8 pt-10 dark:prose-invert","children":[["$","h1",null,{"className":"content-header","id":"1-git-convention","children":[["$","a",null,{"className":"break-words","href":"#1-git-convention","aria-hidden":"true","tabIndex":"-1","children":["$","span",null,{"className":"content-header-link","children":["$","svg",null,{"className":"h-5 linkicon w-5","fill":"currentColor","viewBox":"0 0 20 20","xmlns":"http://www.w3.org/2000/svg","children":[["$","path",null,{"d":"M12.232 4.232a2.5 2.5 0 0 1 3.536 3.536l-1.225 1.224a.75.75 0 0 0 1.061 1.06l1.224-1.224a4 4 0 0 0-5.656-5.656l-3 3a4 4 0 0 0 .225 5.865.75.75 0 0 0 .977-1.138 2.5 2.5 0 0 1-.142-3.667l3-3Z"}],["$","path",null,{"d":"M11.603 7.963a.75.75 0 0 0-.977 1.138 2.5 2.5 0 0 1 .142 3.667l-3 3a2.5 2.5 0 0 1-3.536-3.536l1.225-1.224a.75.75 0 0 0-1.061-1.06l-1.224 1.224a4 4 0 1 0 5.656 5.656l3-3a4 4 0 0 0-.225-5.865Z"}]]}]}]}],"1. Git convention"]}],["$","h2",null,{"className":"content-header","id":"11-các-branch","children":[["$","a",null,{"className":"break-words","href":"#11-các-branch","aria-hidden":"true","tabIndex":"-1","children":["$","span",null,{"className":"content-header-link","children":["$","svg",null,{"className":"h-5 linkicon w-5","fill":"currentColor","viewBox":"0 0 20 20","xmlns":"http://www.w3.org/2000/svg","children":[["$","path",null,{"d":"M12.232 4.232a2.5 2.5 0 0 1 3.536 3.536l-1.225 1.224a.75.75 0 0 0 1.061 1.06l1.224-1.224a4 4 0 0 0-5.656-5.656l-3 3a4 4 0 0 0 .225 5.865.75.75 0 0 0 .977-1.138 2.5 2.5 0 0 1-.142-3.667l3-3Z"}],["$","path",null,{"d":"M11.603 7.963a.75.75 0 0 0-.977 1.138 2.5 2.5 0 0 1 .142 3.667l-3 3a2.5 2.5 0 0 1-3.536-3.536l1.225-1.224a.75.75 0 0 0-1.061-1.06l-1.224 1.224a4 4 0 1 0 5.656 5.656l3-3a4 4 0 0 0-.225-5.865Z"}]]}]}]}],"1.1 Các branch"]}],["$","p",null,{"children":[["$","strong",null,{"children":"Production/Master/Main:"}]," branch tồn tại xuyên suốt quá vòng đời của phần mềm được tạo mặc định trong Git khi ta tạo repository."]}],["$","p",null,{"children":[["$","strong",null,{"children":"Develop:"}]," branch develop phát triển chính, luôn tồn tại song song với master."]}],["$","p",null,{"children":[["$","strong",null,{"children":"Task/Feature:"}]," nhánh được tách từ branch chính nhằm mục đích xây dựng các tính năng riêng mà không phụ thuộc vào nhau."]}],["$","p",null,{"children":[["$","strong",null,{"children":"Staging/Release:"}]," nhánh tách từ branch chính để kiểm tra và fix bug chuẩn bị cho việc ra mắt sản phẩm."]}],["$","p",null,{"children":[["$","strong",null,{"children":"Hotfix:"}]," nhánh tách từ master để fix gấp những bug còn tồn đọng mà trên release chưa xử lý hết Quy tắc đặt tên."]}],["$","p",null,{"children":"Các task branch thường có các loại cơ bản như sau:"}],["$","ul",null,{"children":[["$","li",null,{"children":[["$","strong",null,{"children":"feat"}],": chức năng mới"]}],["$","li",null,{"children":[["$","strong",null,{"children":"change"}],": sửa chức năng"]}],["$","li",null,{"children":[["$","strong",null,{"children":"refactor"}],": tối ưu hóa code"]}],["$","li",null,{"children":[["$","strong",null,{"children":"fix"}],": fix bug"]}],["$","li",null,{"children":[["$","strong",null,{"children":"hotfix"}],": hotfix production"]}],["$","li",null,{"children":[["$","strong",null,{"children":"docs"}],": bổ sung tài liệu"]}],["$","li",null,{"children":[["$","strong",null,{"children":"test"}],": thêm test"]}],["$","li",null,{"children":[["$","strong",null,{"children":"ci"}],": update CI/CD"]}]]}],["$","h3",null,{"className":"content-header","id":"đặt-tên-branch","children":[["$","a",null,{"className":"break-words","href":"#đặt-tên-branch","aria-hidden":"true","tabIndex":"-1","children":["$","span",null,{"className":"content-header-link","children":["$","svg",null,{"className":"h-5 linkicon w-5","fill":"currentColor","viewBox":"0 0 20 20","xmlns":"http://www.w3.org/2000/svg","children":[["$","path",null,{"d":"M12.232 4.232a2.5 2.5 0 0 1 3.536 3.536l-1.225 1.224a.75.75 0 0 0 1.061 1.06l1.224-1.224a4 4 0 0 0-5.656-5.656l-3 3a4 4 0 0 0 .225 5.865.75.75 0 0 0 .977-1.138 2.5 2.5 0 0 1-.142-3.667l3-3Z"}],["$","path",null,{"d":"M11.603 7.963a.75.75 0 0 0-.977 1.138 2.5 2.5 0 0 1 .142 3.667l-3 3a2.5 2.5 0 0 1-3.536-3.536l1.225-1.224a.75.75 0 0 0-1.061-1.06l-1.224 1.224a4 4 0 1 0 5.656 5.656l3-3a4 4 0 0 0-.225-5.865Z"}]]}]}]}],"Đặt tên branch"]}],["$","p",null,{"children":["Format: ",["$","code",null,{"children":"{type}-{ticket_number}-title-in-normal-case"}]]}],["$","p",null,{"children":["Ví dụ: ",["$","code",null,{"children":"feat-FW15-api-list-template"}]]}],["$","p",null,{"children":"Phục vụ mục đích của convention này để :"}],["$","ul",null,{"children":[["$","li",null,{"children":"nhìn là hiểu nhánh để làm gì?"}],["$","li",null,{"children":"link tới backlog để có full description"}]]}],["$","p",null,{"children":"Branch chỉ được xoá khi task liên quan tới branch đã deploy trên production và ở trạng thái close."}],["$","p",null,{"children":"Tùy yêu cầu cụ thể có thể bổ sung thêm ngày tháng vào tên nhánh."}],["$","p",null,{"children":"Nhập commit message"}],["$","p",null,{"children":["Format: ",["$","code",null,{"children":"[type]/(scope) {description}"}]]}],["$","p",null,{"children":"ví dụ:"}],["$","p",null,{"children":["$","code",null,{"children":"feat/posts Add content column"}]}],["$","p",null,{"children":"Nếu 1 commit có nhiều thay đổi thì mô tả cụ thể theo danh sách."}],["$","h1",null,{"className":"content-header","id":"2-git-flow","children":[["$","a",null,{"className":"break-words","href":"#2-git-flow","aria-hidden":"true","tabIndex":"-1","children":["$","span",null,{"className":"content-header-link","children":["$","svg",null,{"className":"h-5 linkicon w-5","fill":"currentColor","viewBox":"0 0 20 20","xmlns":"http://www.w3.org/2000/svg","children":[["$","path",null,{"d":"M12.232 4.232a2.5 2.5 0 0 1 3.536 3.536l-1.225 1.224a.75.75 0 0 0 1.061 1.06l1.224-1.224a4 4 0 0 0-5.656-5.656l-3 3a4 4 0 0 0 .225 5.865.75.75 0 0 0 .977-1.138 2.5 2.5 0 0 1-.142-3.667l3-3Z"}],["$","path",null,{"d":"M11.603 7.963a.75.75 0 0 0-.977 1.138 2.5 2.5 0 0 1 .142 3.667l-3 3a2.5 2.5 0 0 1-3.536-3.536l1.225-1.224a.75.75 0 0 0-1.061-1.06l-1.224 1.224a4 4 0 1 0 5.656 5.656l3-3a4 4 0 0 0-.225-5.865Z"}]]}]}]}],"2. Git Flow"]}],["$","p",null,{"children":"Git flow, là chiến lược mà các dự án phát triển phần mềm áp dụng khi viết, tích hợp và triển khai code khi sử dụng hệ thống Git version control."}],["$","p",null,{"children":"Bài viết sẽ trình bày 3 git flow thường được dùng từ đơn giản đến nâng cao, phù hợp với từng yêu cầu và sự phức tạp của dự án."}],["$","h2",null,{"className":"content-header","id":"21-simple-flow","children":[["$","a",null,{"className":"break-words","href":"#21-simple-flow","aria-hidden":"true","tabIndex":"-1","children":["$","span",null,{"className":"content-header-link","children":["$","svg",null,{"className":"h-5 linkicon w-5","fill":"currentColor","viewBox":"0 0 20 20","xmlns":"http://www.w3.org/2000/svg","children":[["$","path",null,{"d":"M12.232 4.232a2.5 2.5 0 0 1 3.536 3.536l-1.225 1.224a.75.75 0 0 0 1.061 1.06l1.224-1.224a4 4 0 0 0-5.656-5.656l-3 3a4 4 0 0 0 .225 5.865.75.75 0 0 0 .977-1.138 2.5 2.5 0 0 1-.142-3.667l3-3Z"}],["$","path",null,{"d":"M11.603 7.963a.75.75 0 0 0-.977 1.138 2.5 2.5 0 0 1 .142 3.667l-3 3a2.5 2.5 0 0 1-3.536-3.536l1.225-1.224a.75.75 0 0 0-1.061-1.06l-1.224 1.224a4 4 0 1 0 5.656 5.656l3-3a4 4 0 0 0-.225-5.865Z"}]]}]}]}],"2.1. Simple Flow"]}],["$","p",null,{"children":["$","img",null,{"alt":"simple-flow","src":"https://raw.githubusercontent.com/amela-ducdh/public/main/simple-flow.png"}]}],["$","p",null,{"children":"quy trình này khá đơn giản:"}],["$","ul",null,{"children":[["$","li",null,{"children":"lấy nhánh develop là chính"}],["$","li",null,{"children":"các task branch được tách ra từ develop, và được merge lại develop"}],["$","li",null,{"children":"khi triển khai lên staging thì merge từ develop vào staging"}],["$","li",null,{"children":"khi cần sẽ merge từ staging lên master để deploy production"}]]}],["$","p",null,{"children":"flow này chỉ phù hợp với các dự án như sau:"}],["$","ul",null,{"children":[["$","li",null,{"children":"dự án đang ở giai đoạn phát triển, có 1 môi trường dev site và các môi trường staging, production chỉ dùng để demo cho khách hàng."}],["$","li",null,{"children":"dự án có số lượng dev < 5 người."}],["$","li",null,{"children":"các dự án đã sang giai đoạn maintain thì không nên sử dụng flow kiểu này."}]]}],["$","h2",null,{"className":"content-header","id":"22-master-flow","children":[["$","a",null,{"className":"break-words","href":"#22-master-flow","aria-hidden":"true","tabIndex":"-1","children":["$","span",null,{"className":"content-header-link","children":["$","svg",null,{"className":"h-5 linkicon w-5","fill":"currentColor","viewBox":"0 0 20 20","xmlns":"http://www.w3.org/2000/svg","children":[["$","path",null,{"d":"M12.232 4.232a2.5 2.5 0 0 1 3.536 3.536l-1.225 1.224a.75.75 0 0 0 1.061 1.06l1.224-1.224a4 4 0 0 0-5.656-5.656l-3 3a4 4 0 0 0 .225 5.865.75.75 0 0 0 .977-1.138 2.5 2.5 0 0 1-.142-3.667l3-3Z"}],["$","path",null,{"d":"M11.603 7.963a.75.75 0 0 0-.977 1.138 2.5 2.5 0 0 1 .142 3.667l-3 3a2.5 2.5 0 0 1-3.536-3.536l1.225-1.224a.75.75 0 0 0-1.061-1.06l-1.224 1.224a4 4 0 1 0 5.656 5.656l3-3a4 4 0 0 0-.225-5.865Z"}]]}]}]}],"2.2. Master Flow"]}],["$","p",null,{"children":["$","img",null,{"alt":"master-flow","src":"https://raw.githubusercontent.com/amela-ducdh/public/main/master-flow.png"}]}],["$","p",null,{"children":"Hãy cùng xem xét 1 case như sau:"}],["$","ul",null,{"children":[["$","li",null,{"children":"dự án đã sang giai đoạn maintain"}],["$","li",null,{"children":"khách hàng muốn thực hiện feature A, team phát triển đã done và merge lên staging"}],["$","li",null,{"children":"tuy nhiên khách hàng lại muốn thực hiện gấp feature B và muốn đưa lên production trước, hoặc trong trường hợp khách không muốn release feature A nữa."}],["$","li",null,{"children":"nếu vẫn làm theo simple flow như phía trên, thì khi merge staging vào master sẽ phải release cả feature A & B, điều này là không hợp lý."}]]}],["$","p",null,{"children":"vì vậy, có 1 flow độc lập hơn như sau:"}],["$","ul",null,{"children":[["$","li",null,{"children":"lấy nhánh master là chính, để đảm bảo chỉ lấy code đã được release."}],["$","li",null,{"children":"các task branch được tách ra từ master."}],["$","li",null,{"children":"khi cần deploy lên dev site thì merge task branch vào nhánh develop."}],["$","li",null,{"children":"khi cần deploy lên staging site thì merge task branch vào nhánh staging."}],["$","li",null,{"children":"khi cần deploy lên production thì merge task branch vào nhánh master."}],["$","li",null,{"children":"điều này có thể đảm bảo các task branch được release độc lập và không ảnh hưởng lẫn nhau."}],["$","li",null,{"children":"không được phép merge develop vào staging, master."}]]}],["$","p",null,{"children":"Flow này phù hợp với các trường hợp:"}],["$","p",null,{"children":"dự án đang ở giai đoạn maintain và khách hàng thường xuyên thay đổi yêu cầu. code trên các nhánh develop, staging, master đã có nhiều sự khác biệt trong quá trình phát triển."}],["$","h2",null,{"className":"content-header","id":"32-gitflow","children":[["$","a",null,{"className":"break-words","href":"#32-gitflow","aria-hidden":"true","tabIndex":"-1","children":["$","span",null,{"className":"content-header-link","children":["$","svg",null,{"className":"h-5 linkicon w-5","fill":"currentColor","viewBox":"0 0 20 20","xmlns":"http://www.w3.org/2000/svg","children":[["$","path",null,{"d":"M12.232 4.232a2.5 2.5 0 0 1 3.536 3.536l-1.225 1.224a.75.75 0 0 0 1.061 1.06l1.224-1.224a4 4 0 0 0-5.656-5.656l-3 3a4 4 0 0 0 .225 5.865.75.75 0 0 0 .977-1.138 2.5 2.5 0 0 1-.142-3.667l3-3Z"}],["$","path",null,{"d":"M11.603 7.963a.75.75 0 0 0-.977 1.138 2.5 2.5 0 0 1 .142 3.667l-3 3a2.5 2.5 0 0 1-3.536-3.536l1.225-1.224a.75.75 0 0 0-1.061-1.06l-1.224 1.224a4 4 0 1 0 5.656 5.656l3-3a4 4 0 0 0-.225-5.865Z"}]]}]}]}],"3.2. GitFlow"]}],["$","p",null,{"children":"Đây là flow được cho là lý tưởng và được công nhận, áp dụng nhiều nhất."}],["$","p",null,{"children":["$","img",null,{"alt":"gitflow","src":"https://raw.githubusercontent.com/amela-ducdh/public/main/gitflow.png"}]}],["$","p",null,{"children":"Quy trình thực hiện:"}],["$","ul",null,{"children":[["$","li",null,{"children":"lấy branch develop là chính, branch develop ban đầu được tạo ra từ branch master."}],["$","li",null,{"children":"các task branch được tách ra từ develop, và được merge lại develop."}],["$","li",null,{"children":"khi cần release lên staging thì tạo 1 branch mới từ develop và merge vào staging, nếu có những thay đổi trên staging thì cần merge ngược lại staging vào develop."}],["$","li",null,{"children":"khi cần release lên production thì tạo 1 branch release mới từ staging và merge vào master."}],["$","li",null,{"children":"khi cần hotfix thì tách branch từ master, và merge vào master luôn, sau đó branch hotfix cũng được merge lại develop để cập nhật các thay đổi."}]]}],["$","p",null,{"children":"Flow này có thể áp dụng được cho cả dự án đang trong giai đoạn phát triển và maintain."}],["$","p",null,{"children":"Tuy nhiên có một số lưu ý khi sử dụng flow này:"}],["$","p",null,{"children":"code trên các branch develop, staging, master cần được đảm bảo là không có nhiều sự khác biệt. nếu trong 1 sprint có nhiều feature cần được thực hiện, thì phải được lên plan kỹ càng, tránh những thay đổi liên tục."}],["$","p",null,{"children":["Tìm hiểu thêm về GitFlow: ",["$","a",null,{"className":"break-words","target":"_blank","rel":"noopener noreferrer","href":"https://nvie.com/posts/a-successful-git-branching-model/","children":"https://nvie.com/posts/a-successful-git-branching-model/"}],"."]}]]}],["$","div",null,{"className":"pb-6 pt-6 text-center text-gray-700 dark:text-gray-300","id":"comment","children":["$","$L10",null,{"slug":"git-flow"}]}]]}],["$","footer",null,{"children":[["$","div",null,{"className":"divide-gray-200 text-sm font-medium leading-5 dark:divide-gray-700 xl:col-start-1 xl:row-start-2 xl:divide-y","children":[["$","div",null,{"className":"py-4 xl:py-8","children":[["$","h2",null,{"className":"text-xs uppercase tracking-wide text-gray-500 dark:text-gray-400","children":"Tags"}],["$","div",null,{"className":"flex flex-wrap","children":[["$","$L9",null,{"href":"/tags/git","className":"mr-3 text-sm font-medium uppercase text-primary-500 hover:text-primary-600 dark:hover:text-primary-400","children":"git"}],["$","$L9",null,{"href":"/tags/gitflow","className":"mr-3 text-sm font-medium uppercase text-primary-500 hover:text-primary-600 dark:hover:text-primary-400","children":"gitflow"}]]}]]}],["$","div",null,{"className":"flex justify-between py-4 xl:block xl:space-y-8 xl:py-8","children":[["$","div",null,{"children":[["$","h2",null,{"className":"text-xs uppercase tracking-wide text-gray-500 dark:text-gray-400","children":"Previous Article"}],["$","div",null,{"className":"text-primary-500 hover:text-primary-600 dark:hover:text-primary-400","children":["$","$L9",null,{"className":"break-words","href":"/blog/fine-tuning","children":"Embedding và Fine-tuning trong Large Language Model"}]}]]}],["$","div",null,{"children":[["$","h2",null,{"className":"text-xs uppercase tracking-wide text-gray-500 dark:text-gray-400","children":"Next Article"}],["$","div",null,{"className":"text-primary-500 hover:text-primary-600 dark:hover:text-primary-400","children":["$","$L9",null,{"className":"break-words","href":"/blog/aws-best-practice","children":"AWS Best Practice for Beginner"}]}]]}]]}]]}],["$","div",null,{"className":"pt-4 xl:pt-8","children":["$","$L9",null,{"className":"text-primary-500 hover:text-primary-600 dark:hover:text-primary-400","href":"/blog","aria-label":"Back to the blog","children":"← Back to the blog"}]}]]}]]}]]}]}]]}]] d:[["$","meta","0",{"name":"viewport","content":"width=device-width, initial-scale=1"}],["$","meta","1",{"charSet":"utf-8"}],["$","title","2",{"children":"Git Convention and Git Flow Cơ Bản và Nâng Cao | Homepage | ducdh.com"}],["$","meta","3",{"name":"description","content":"Git Convention and Git Flow Cơ Bản và Nâng Cao"}],["$","meta","4",{"name":"robots","content":"index, follow"}],["$","meta","5",{"name":"googlebot","content":"index, follow, max-video-preview:-1, max-image-preview:large, max-snippet:-1"}],["$","link","6",{"rel":"canonical","href":"https://ducdh.com/blog/git-flow"}],["$","link","7",{"rel":"alternate","type":"application/rss+xml","href":"https://ducdh.com/feed.xml"}],["$","meta","8",{"property":"og:title","content":"Git Convention and Git Flow Cơ Bản và Nâng Cao"}],["$","meta","9",{"property":"og:description","content":"Git Convention and Git Flow Cơ Bản và Nâng Cao"}],["$","meta","10",{"property":"og:url","content":"https://ducdh.com/blog/git-flow"}],["$","meta","11",{"property":"og:site_name","content":"Homepage | ducdh.com"}],["$","meta","12",{"property":"og:locale","content":"en_US"}],["$","meta","13",{"property":"og:image","content":"https://ducdh.com/"}],["$","meta","14",{"property":"og:type","content":"article"}],["$","meta","15",{"property":"article:published_time","content":"2023-06-09T00:00:00.000Z"}],["$","meta","16",{"property":"article:modified_time","content":"2023-06-09T00:00:00.000Z"}],["$","meta","17",{"property":"article:author","content":"Duc Dao"}],["$","meta","18",{"name":"twitter:card","content":"summary_large_image"}],["$","meta","19",{"name":"twitter:title","content":"Git Convention and Git Flow Cơ Bản và Nâng Cao"}],["$","meta","20",{"name":"twitter:description","content":"Git Convention and Git Flow Cơ Bản và Nâng Cao"}],["$","meta","21",{"name":"next-size-adjust"}]] 1:null