From e117a5bd19f03865e6863543cc8a21ec59950847 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 12:19:58 +0100
Subject: [PATCH 01/46] adds rename action to blob.rb

---
 lib/gitlab_git/.blob.rb.swp | Bin 0 -> 24576 bytes
 lib/gitlab_git/blob.rb      |  35 +++++++++++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)
 create mode 100644 lib/gitlab_git/.blob.rb.swp

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..b08749de7612c6e07c1f48b64a9f5c8238e677ec
GIT binary patch
literal 24576
zcmeI44U8ODeZZ%Q^Wij3(gcM-34Oi;?_P7By$jCQ66fqBHZj=2IU7<qpEq;6v$qrP
z&TMC9eZJTxIH9c+LWKedHzZVPN=4ezs6a&<sima|f*Q3|T2xvE3REo#tq2mPh<>R3
z{ok9}nb|uNyJ=CC%t*i6`FNlI_n-IP|Nq|H!qnS$>{8d*n=FotEbE%>cisLMGmoEf
zbh~B6p0gPE3qkC5JAphu$+7Fk-5Xo(#=R1J<CS*T@mCM{u0n#fC~Vf=<i%ZQp|+@h
z8vN9{Ug2_~8!Xu2!s-c@cS{MB5;!#p4C402Yu8zCxN>?*B8-o%SC?G;wo{8+hAJgc
zN}!ZLDS=V~r36X|loBW<P)gt>A%VER#=4uDoRQS#uH^S8Mt;vqt~VsVhew{TNv>1V
z|05&M&rGhh@xl4Oj66>+%b!vLr36X|loBW<P)eYbKq-Mz0;L2>36v5jB~VJ>|3Csx
z%d*BucY`<pSpQG$|F2$XS$_n72#>?B!3UrZdtesMg3n!GSrKf9pMlrHm)2R<lkjP{
z9~NK>%)p8BE$e&m6#N-H0s-6s6HtX$z<>OtWql2P4?YO*fY-sf@a%b(^%Zy$o`Bzh
zPr&`qf+oBbu7b<p8*44=%kU+55*~#2!#ywun_wOM)47)Q3_K0*g=6q0xD-yDL!R&{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Hlmm^Phz;!ZMr<XTg^#
z*Kfl^AY~NW|6bS+YvEjYn)2TV+h7fxz=r=Gd;#u*BXAhR&c7C33E#zr|2#Ybcf-42
z7PiASSPTD!4gcrx1iT-P!2!4tWKaJZ_&)agGaxqp12BL#?1l|+4*U>%{dxEz9Ebbi
z9ykU~7>DPv-~R!=34a3bg?%s!x4{;89lRP|1?Pe6?f*7B2ghLvX5nIZ4xi4m=|6Fh
zHkG!Qqcm(SEeHOThV4thuq~(gFX1mv%4z<vvr6ai<ut#X=D$3q`8m~J%^WimUA`a_
zpN@F1R-f<k-sGM!L6%GDR~j-m*6!PEa%5%(r#Q1uru*8<YfQi_S#j+S3nZC1*|$;^
zzI7{FrlyR;*c5U%1vJ}%`3f=YX=kwcK1ymiS1<VSa?WR|0G2}foh2VOVb@U4oGe%D
z!!HPOH6e~BC=$=hY}7PMx+tnK#~$^#VO$CMubfgtUMwQx4af!5+vbY`$~`63P`gjW
z7h<y^0aGVeJ0`d%v&&`)FCV0gr4463EY+_1%=F3<FQz)oQwktH1hU7h_StGb$7#NH
zi4mtm6_-0`9b=%SiD=p9GD^kI^PxJd(9x6DuxNRv)s%!@jDC)*tqVcOY6^PgFH?SP
z<*Ftw0Q8JqAjpHyUVT+{ZMN*&cC8%*`Su&ugj&6zVpCZ3IVX})?Lye3Q{gA7b<m%v
zR#8__guJ(9*aEEG<o2wXNW6Tx<a5fJZ$pzy>LoLpQhbiXrSM6dQJh@LCNhB%Z@G9j
z<kRSUGUkqa@~|S9xZZN98TVQ~SmJuig-KirsUyW)&fDyKnc<sES?}kQOw)lR&#eCj
D6{d&6

literal 0
HcmV?d00001

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 4c6850e..3d0b45b 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -150,6 +150,14 @@ module Gitlab
           if action == :remove
             index.remove(filename)
           else
+            if action == :rename
+              old_path_name = PathHelper.normalize_path(file[:previous_path])
+              raise Repository::InvalidBlobName.new("Invalid path") if path_name.each_filename.to_a.include?('..')
+
+              old_filename = old_path_name.to_s
+              index.remove(old_filename)
+            end
+
             mode = 0100644
             file_entry = index.get(filename)
 
@@ -207,6 +215,33 @@ module Gitlab
         def remove(repository, options)
           commit(repository, options, :remove)
         end
+
+
+        # Rename file from repository and return commit sha
+        #
+        # options should contain next structure:
+        #   file: {
+        #     previous_path: 'documents/old_story.txt'
+        #     path: 'documents/story.txt'
+        #   },
+        #   author: {
+        #     email: 'user@example.com',
+        #     name: 'Test User',
+        #     time: Time.now
+        #   },
+        #   committer: {
+        #     email: 'user@example.com',
+        #     name: 'Test User',
+        #     time: Time.now
+        #   },
+        #   commit: {
+        #     message: 'Rename FILENAME',
+        #     branch: 'master'
+        #   }
+        #
+        def rename(repository, options)
+          commit(repository, options, :rename)
+        end
       end
 
       def initialize(options)
-- 
GitLab


From 98d542a6270064a74c6bd6028ce50203b9c876ec Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 12:44:04 +0100
Subject: [PATCH 02/46] fixes accuracy of comments on rename method

---
 lib/gitlab_git/.blob.rb.swp | Bin 24576 -> 24576 bytes
 lib/gitlab_git/blob.rb      |   2 ++
 2 files changed, 2 insertions(+)

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
index b08749de7612c6e07c1f48b64a9f5c8238e677ec..02ca93df3597f403f8fc2553d007f24b33b081d1 100644
GIT binary patch
delta 283
zcmXBPF-t;W6vpxM)=d$KZU`c@NO=h^qJc`#V1aN$qM*g1F|MnM;-Z6o0wG>-Y6x<2
zix*nEOD)>sQbW5CNRwMZ|LDLE4m|L1PCronK*g{3D&^DUekL!BE%JWSxrllX@dH~m
z%(-o{>t6(umH)J1HjkpJHwcTg;NuJqEX+d`;0Z&tafvc=h~RTg<O4H|(M26q`0x<I
z%o2IQGe)T45Cuz$l4sdL7(c5b-&o)cub85XD-^Kg{we<cxYKIexe4yIU2@Gv>Cw{Z
R)Ru0hcJ*z=HH+g|;uq4_G>ZTL

delta 262
zcmXBOze@sf9LDj_x4RSz@p}YEV8e}pa4H6eI;2AW3I`Y4Tf*g5wI!h~Xt6bJYS8ig
zPEO~4&>Dfe4f!|ph8}pq1JClzw`#ss?tN+08+d_#B}9t^?Z>;%>)5Sn6`G+o#cW-P
z<gEWSG*07GJuTBB3yjf40T;0Fof6sL9j};R03RM)9F9d27_6|w3;J+zf(-Vy$QsX>
vVTuP^DsoF{qJc8<aG;U!HNp&4XymLoZYlFK{5mopH#_wfjV{e^=j{9sem5$1

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 3d0b45b..075bafa 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -223,6 +223,8 @@ module Gitlab
         #   file: {
         #     previous_path: 'documents/old_story.txt'
         #     path: 'documents/story.txt'
+        #     content: 'Lorem ipsum...',
+        #     update: true
         #   },
         #   author: {
         #     email: 'user@example.com',
-- 
GitLab


From 0e4ac299b806fa4190c4928a1c1ed5372fffbb38 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 14:36:22 +0100
Subject: [PATCH 03/46] fixes bug regarding old_path_name in blob.rb's commit
 method

---
 lib/gitlab_git/blob.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 075bafa..3e186a1 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -152,7 +152,7 @@ module Gitlab
           else
             if action == :rename
               old_path_name = PathHelper.normalize_path(file[:previous_path])
-              raise Repository::InvalidBlobName.new("Invalid path") if path_name.each_filename.to_a.include?('..')
+              raise Repository::InvalidBlobName.new("Invalid path") if old_path_name.each_filename.to_a.include?('..')
 
               old_filename = old_path_name.to_s
               index.remove(old_filename)
-- 
GitLab


From 0b9ab579512a68fc5a7bc98b392fb6f15c1c26b9 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 10:38:09 +0100
Subject: [PATCH 04/46] removes .swp file

---
 lib/gitlab_git/.blob.rb.swp | Bin 24576 -> 0 bytes
 lib/gitlab_git/blob.rb      |   2 --
 2 files changed, 2 deletions(-)
 delete mode 100644 lib/gitlab_git/.blob.rb.swp

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
deleted file mode 100644
index 02ca93df3597f403f8fc2553d007f24b33b081d1..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 24576
zcmeI44U8ODeZZ%Q^I?cXl^_VHq0e{3yI0P$=fn=lHqO~eY+`VNb2bEWK5yoBXKyFo
zo!QRJ`h2lXa6(%NQiQ^n8%WzUPzhQZ6{x5p^^4LFgj-c<5vc?esM>t=!$>$qw4nC)
ze{W`IX73!^O<PrAM*7{($D8-@fB$*&{{R1*o1c37j$70l?Tr@OPg~YgZ@K&Smv4Xc
zoFm&UEB2g)z@HCdx7!Ki`YE<sZrHWH<*wf&$=6?LcO8G_gzqY3Sc}4D?M+_Xb>?de
z`lrE9t?LyI=exnY9nP<uVR^QcKq-MUlfWQuufJxEb=8#{rsRh4v9;>bOWt;7_m-(j
z36v5jB~VJBlt3wgQUav}N(qz_cu7bg?ys`$p(W=et+_k-{i%`P^OECr$?u_&>#LIE
ze)9XVk?ZFs$J+Q{|DQ*$Cx_)vDS=V~r36X|loBW<P)eYbKq-Mz0;L2>36v5jCGfu>
z0jFhIW8}L|900`sQ~Up$udu8?f<J^u;Wy!f(1+bH1LwgPFSe`*w!_cD>)<PEEb9sQ
zJlqfSumz^!<VBYCeK-zZg@+-4J7EH<@Jjg6%Ps3$@cZx~cqhCbE`(=Z#ySOf0v?0k
zh0nnK(1Iqs6*j?T@SW9`^)>hkJOK~F2jE_qg^jQV{_#S~`UX4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u%cE
zufqT&)^EebAhG^`gX8d9a112we+Rq<K8?-)DfmU`zyiD(B)0!J_Wpy=g`1%c*TQSz
z2iW<~z?WeO&WH2hYt-v^;Nu{56x;tk*axfOLU@w;zZbT_DmaM^|9yBI-V2A}5Qv?B
z4ZIq@haLYVco^=1cfky7hi$ML{u4X?FX1ux033z=a0AGi{#EciHoVyRpMwWr0BzU>
z>)-<TA@=(T_%a-W`{7<V3QZ6j{{;5?-@|v|PvL#A7iQo#*aEMI*TQSyWgu(&pMz)N
z7%ajJTmsMX4;-FJ|A~Y2sr0>UrEzR&Iq;`6j$Z=CaXHO@34d`?PV<L@RXT?+r}^bH
z|0iRbpHuyn%rP_3<qI<L>4^7g<@qkpP3{^KWI5EUWMyuwUBKDo$jl7RaAu!O_qC_k
zn1ETf;vODWND6VXZ>1`H>sGW(O&y1KQ^{Q{<2B2H`3f=YX@|1;K1y0STQB(Wat>^1
z0G2}foh2VOVb{>koGh2E!!HPOB_WPxC=$=hY}7PMhA5gb%Nq5#VO$CMubfgtUMwQx
z4ag<b%jSy$%3USbP`gjW7h<y@0aGW}IwrWMvdd;jFCV0gr5$HJEY<G*%=F4KFXlQd
zQz{@n1d7M3_E~B_%Wl4Pi4mt$6+<TUjxo^EOtkEC1*PKW`cNH~>F6n2ShPITW=cjc
zMnA{Z*7+bLB7<J}OVnRmxvGf^06k+B2=d^wS6@|Kn<e|UU26wHzW;_Tp;f0<Y$}UB
z=R`89T?m_eD*QyX4*C<-D(VeXA@6M&_5ksp+?o}06Axc5`<$}o`_Pn<ddZBY6tClO
zDSQ%V6epLnxtT<Xw_H3M@@aHF8*@fJd03WATyMGDjC(DgEOEW%(j+d0)RAHi=WJHK
TO!G~q#QXUq(+nWVHS50s-n_1q

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 3e186a1..3ddcbf5 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -152,8 +152,6 @@ module Gitlab
           else
             if action == :rename
               old_path_name = PathHelper.normalize_path(file[:previous_path])
-              raise Repository::InvalidBlobName.new("Invalid path") if old_path_name.each_filename.to_a.include?('..')
-
               old_filename = old_path_name.to_s
               index.remove(old_filename)
             end
-- 
GitLab


From 18982ce44337ca0fc2b37280c41c3f2826749c2b Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 11:23:23 +0100
Subject: [PATCH 05/46] adds tests for renaming a file

---
 spec/.blob_snippet_spec.rb.swp | Bin 0 -> 12288 bytes
 spec/.blob_spec.rb.swp         | Bin 0 -> 28672 bytes
 spec/.spec_helper.rb.swp       | Bin 0 -> 12288 bytes
 spec/blob_spec.rb              |  48 +++++++++++++++++++++++++++++++++
 4 files changed, 48 insertions(+)
 create mode 100644 spec/.blob_snippet_spec.rb.swp
 create mode 100644 spec/.blob_spec.rb.swp
 create mode 100644 spec/.spec_helper.rb.swp

diff --git a/spec/.blob_snippet_spec.rb.swp b/spec/.blob_snippet_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..ddfee16af275096b2c18d97b3a746bd6d8f4ad99
GIT binary patch
literal 12288
zcmeI2&uY|A6vl50ZiK4X7dVZJ%)m_28HLv1Y8DlRf?%r)m5@J&nLy^=G`VG}qV0?L
z4B|WZ0Iqc9Bj^(-cy1@--xdq5D&K`KC%HNI%elX-LQcB=;LbK}1UHn7D@t7)J$txy
z^Y!xEHKlBkjEzo><#J-&{Zq#F=w3hP{*FuU4}&t%CnvuA#V~B@EWBOVGD*Ynafl^^
zO~qN5mL`oGT~rm@*v$lWda@^GK>!5KN?=7@9}d=C_BC&fR<G`!bs_RV00ck)1V8`;
zKmY_l00jO60=8OGhq905b}y@KT>34xmk1yL0w4eaAOHd&00JNY0w4eaAOHgAkU)|v
z^=?I}%}Y|e{QqBk|9`%$)F;sg(R<Mw(JRrBXeb(pE{ML$x-X)Sq9f6v=&ooax+QYH
z8zKx4009sH0T2KI5C8!X009sHf%8d#b*_l!#~+cXu=JexKw7qKr)}U4^28?Hz#8Jc
zjyE&2$9lS-O}s9>P~zc6$+i=<>0L3Hw}nTM#3&j`Gx+^^FL<DN*72uFW4ZQw^vD-C
ziN5pmpY&)T=Q1VT;=Xft)|t_k4=njr%?)cyWudw8DL3<nFShWP(o>FgQT}tq;?bkU
z;g1q|TG^*R6-bnGlhsAa6gh~l=<hS9F*@E^&3pSr&E&b}`FO%*#kD70zw*X1lNWj%
L(eBPxe^Y$}9_PtW

literal 0
HcmV?d00001

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..55948ef86f930d92ca44f0f38400a5a9ba0df0cd
GIT binary patch
literal 28672
zcmeI44~!gFea9y$32jOeFltKDQa$fU-7`M#?f-vCNY3^F4nEsGpD}T;wzD&D@5bJp
zS!QN^w{aXp0wJV?icmx)TH3@hL=cjo6a|w4{SyePigPKDsDXltBM=b@g3utOM(y|a
z=I{Q!J^LIIG%I~>_h#O_dGGgr@6Ye|elykNJGRZRLLw{S^IAzda@*m(w~s$??j!3Z
z$=2j~L$4Y(uP+#Me!ypD^R7)Q-!w<bH>DGGS?{0l#*PdpEmN6%t7g~b>g2rms^DwV
zYI0?=S~sc{`js%N{qu^BMiPi5unGyZ?AoT{g;FM+O43zhvGwfr>-MZ7gD7bvfk*<8
z1R@DU5{M)aNg$FyB!Nf*uXG96&GV$AsKmK$MY#KYPS^MO?*E=?U+X&mD);}o`~B^%
z^XIw$zuEm>=ib1(&+oX$%kKA%uJi8U=qr*yB!Nf*kpv<ML=uQ35J@1CKqP@k0+9qF
z2}BY&4GGAqB>e%d`x@EX*#GzJ|K~22q-VjC;0f?W&;mBt2gX1QoCkhzktF>ixC7h<
z-Un_52G|LnxlodR0`3C_$bjcxBT2_V8(af6gDEfu9{qhu`Z`zyTfytV;}=NM$G|~w
z1;~O7I2RoMJxRJ7>;W<Gv)`4Z`+)_vfy=-;@H+7GS0f+rSD*<Nz&v;xcp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l05
zs44V9C>?)E==63Tp=o#(j9kMeuN!BE2nB}MJh^JU2CCDsE)9jm_he0_N?;AfEhkXI
zTmQtCk1v1a@%MmRm%q4tf<6Ae<p-8eEI&N5T9_@oXGQj(^mnUv`aQP4PITR6fI_&b
z0)+^Vr(VzZI<dF#^uEKL8o!4>h#$QD$gS|oFAVY%hO_QfF&qhpeTEY|ZP@WTs~+#y
zfVY?hYnO0_eTM2Y%P_2tArbjir(^vhzIxsXX13<%@$LiRx%00M9YiLxB8l_vwnWV|
d8Wra~a3N<=!ntCCIcE|F@Ce&DUh=d-`hQwNYCQk|

literal 0
HcmV?d00001

diff --git a/spec/.spec_helper.rb.swp b/spec/.spec_helper.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..1246342965bda0d19fc0e816501ebebf323977e9
GIT binary patch
literal 12288
zcmeI2PmkL~6u_rFfK(_TK%xf@v&+F7(Kzi=6%lC<*^=$9lx(8>Sq^9!jqR6Ys<Fq6
z$0>p3&xtDs1QL7(1SdWK2*GDS9QXoAd;mD`Y=`{=+a*14sPruTGP2*B@tfb+k)lj+
z<6y7LU-fS>Jf30f%J#c&^j`bs@(*i_IVGni35)|hGe!IXM|ZnlkDxv(((9YPmdW{v
zADkJmk=d|uS2-<%#<Xk%HjONWu>24+&?#8o2Ir4PSIGbwcsK)B*(;kjZxnrAT3_SO
zJv)B5?vzai$N(8217v^<kO4A42FSo8ZNR0M*oQcS%gb53ylgN1qg|d-Lk7qI86X2>
zfDDiUGC&5%02v?yWPl7jf(B&7*u5)^Z9aj;<NyDE|Nj5|X~up=enP%SzCyl4K1V)7
zK0++=7IKK(MxIB0dy28|kS`F6bPx}D9C-}+<tmPee2aX72xJ|35xIuEfc*F*V;>_e
z<WH>Y59C+mYvfa8fgB>Yk)rOK2pwdA43GgbKnBPF86X2>;QuiINyIo0O)^naKY)p`
zu+fxS*Z6xJk}S6%GJq)K@1LZpB-D8Xe29VFa$D<3%-9Gl-{PK?Nn~R0Br;LjffY7S
zcynUHJUa>DHG%gO_h*m@n1fxonM$Uj>H-mt=WGsaFvRV&epM`1#v{Xzs<R`;M(yE9
zbjPFCcBd@{?S4=6Tccg<x}!As_l!z5hU0#}HyD+H>wG=VoeVV8Eu_ZB-MZ_wYLNZj
zpxf%KHb!DxJ&^X_gRD}4SM3z8V^epKxuOWK#!i=crv7p!@J@<qMJnBFqr4C)o5&b8
zgxJ}`sf$|eI`@3Pk>zP>Y%w6KR=N7*T!t=}+LyVT87qpud~2&*%>kNdHt(1?R<7A>
zjYqq^f!G;$I%2=oZR3I+ca9;;<n#d@yY1nyb@xoZ!bLpq9(%8!8kMhY@kD975=$4(
z%Jr>^J*w8e+3Xepu$dphL?ytR0f@QODiUE?HTJ=uYVdZh@X58HrBid@-qJ;*SZeR0
zcpfZ7piOX5QlO^GyIqu}W#(2$n<%?d9wecOikG6A=S6phICYB^^8S0I;?-a7T=$N(
z;=5gLYgaBiu7Z21U7R|r9_(TZJoc-eyP=9x4R_4k&z!Ul7kRl%xH@GhG;@!E&HzK0
k1{S{(GXFkEyLLJm)2fii)P%S958m`fgVw>`&^u&*0gcb<CIA2c

literal 0
HcmV?d00001

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 6998ea3..969d058 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -270,6 +270,54 @@ describe Gitlab::Git::Blob do
     end
   end
 
+  describe :rename do
+    let(:repository) { Gitlab::Git::Repository.new(TEST_NORMAL_REPO_PATH) }
+
+    let(:commit_options) do
+      options = {
+        file: {
+          path: 'NEWREADME.md',
+          previous_path: 'README.md',
+          content: 'Lorem ipsum...',
+          update: true
+        },
+        author: {
+          email: 'user@example.com',
+          name: 'Test User',
+          time: Time.now
+        },
+        committer: {
+          email: 'user@example.com',
+          name: 'Test User',
+          time: Time.now
+        },
+        commit: {
+          message: 'Rename readme',
+          branch: 'master'
+        }
+      }
+    end
+
+    let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
+    let!(:commit) { repository.lookup(commit_sha) }
+
+    it 'should rename the file with commit' do
+      # Commit message valid
+      expect(commit.message).to eq('Rename readme')
+
+      # Previous file was removed
+      expect(commit.tree.to_a.any? do |tree|
+        tree[:name] == 'README.md'
+      end).to be_falsey
+
+      # File was renamed
+      expect(commit.tree.to_a.any? do |tree|
+        tree[:name] == 'NEWREADME.md'
+      end).to be_truthy
+
+    end
+  end
+
   describe :remove do
     let(:repository) { Gitlab::Git::Repository.new(TEST_REPO_PATH) }
 
-- 
GitLab


From 7ca18bf5aa5ce7b08548680f7a0250650ab0fc63 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 12:11:28 +0100
Subject: [PATCH 06/46] removes swp files

---
 spec/.blob_snippet_spec.rb.swp | Bin 12288 -> 0 bytes
 spec/.blob_spec.rb.swp         | Bin 28672 -> 0 bytes
 spec/.spec_helper.rb.swp       | Bin 12288 -> 0 bytes
 3 files changed, 0 insertions(+), 0 deletions(-)
 delete mode 100644 spec/.blob_snippet_spec.rb.swp
 delete mode 100644 spec/.blob_spec.rb.swp
 delete mode 100644 spec/.spec_helper.rb.swp

diff --git a/spec/.blob_snippet_spec.rb.swp b/spec/.blob_snippet_spec.rb.swp
deleted file mode 100644
index ddfee16af275096b2c18d97b3a746bd6d8f4ad99..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 12288
zcmeI2&uY|A6vl50ZiK4X7dVZJ%)m_28HLv1Y8DlRf?%r)m5@J&nLy^=G`VG}qV0?L
z4B|WZ0Iqc9Bj^(-cy1@--xdq5D&K`KC%HNI%elX-LQcB=;LbK}1UHn7D@t7)J$txy
z^Y!xEHKlBkjEzo><#J-&{Zq#F=w3hP{*FuU4}&t%CnvuA#V~B@EWBOVGD*Ynafl^^
zO~qN5mL`oGT~rm@*v$lWda@^GK>!5KN?=7@9}d=C_BC&fR<G`!bs_RV00ck)1V8`;
zKmY_l00jO60=8OGhq905b}y@KT>34xmk1yL0w4eaAOHd&00JNY0w4eaAOHgAkU)|v
z^=?I}%}Y|e{QqBk|9`%$)F;sg(R<Mw(JRrBXeb(pE{ML$x-X)Sq9f6v=&ooax+QYH
z8zKx4009sH0T2KI5C8!X009sHf%8d#b*_l!#~+cXu=JexKw7qKr)}U4^28?Hz#8Jc
zjyE&2$9lS-O}s9>P~zc6$+i=<>0L3Hw}nTM#3&j`Gx+^^FL<DN*72uFW4ZQw^vD-C
ziN5pmpY&)T=Q1VT;=Xft)|t_k4=njr%?)cyWudw8DL3<nFShWP(o>FgQT}tq;?bkU
z;g1q|TG^*R6-bnGlhsAa6gh~l=<hS9F*@E^&3pSr&E&b}`FO%*#kD70zw*X1lNWj%
L(eBPxe^Y$}9_PtW

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
deleted file mode 100644
index 55948ef86f930d92ca44f0f38400a5a9ba0df0cd..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 28672
zcmeI44~!gFea9y$32jOeFltKDQa$fU-7`M#?f-vCNY3^F4nEsGpD}T;wzD&D@5bJp
zS!QN^w{aXp0wJV?icmx)TH3@hL=cjo6a|w4{SyePigPKDsDXltBM=b@g3utOM(y|a
z=I{Q!J^LIIG%I~>_h#O_dGGgr@6Ye|elykNJGRZRLLw{S^IAzda@*m(w~s$??j!3Z
z$=2j~L$4Y(uP+#Me!ypD^R7)Q-!w<bH>DGGS?{0l#*PdpEmN6%t7g~b>g2rms^DwV
zYI0?=S~sc{`js%N{qu^BMiPi5unGyZ?AoT{g;FM+O43zhvGwfr>-MZ7gD7bvfk*<8
z1R@DU5{M)aNg$FyB!Nf*uXG96&GV$AsKmK$MY#KYPS^MO?*E=?U+X&mD);}o`~B^%
z^XIw$zuEm>=ib1(&+oX$%kKA%uJi8U=qr*yB!Nf*kpv<ML=uQ35J@1CKqP@k0+9qF
z2}BY&4GGAqB>e%d`x@EX*#GzJ|K~22q-VjC;0f?W&;mBt2gX1QoCkhzktF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o%~!
zZlWULr7PG(cAF!tbZ4O<5G66{z?jJn>v!}pubAjGU8%QJJ{~*u-jANT=|iX9d;h7M
zZ#i|-iBmV<I_ypzZR20DcCFLDWqNNkpl!A+XgVS>MsJ#KjbA~~D|V?dHrqmkCtl05
zs44V9C>?)E==63Tp=o#(j9kMeuN!BE2nB}MJh^JU2CCDsE)9jm_he0_N?;AfEhkXI
zTmQtCk1v1a@%MmRm%q4tf<6Ae<p-8eEI&N5T9_@oXGQj(^mnUv`aQP4PITR6fI_&b
z0)+^Vr(VzZI<dF#^uEKL8o!4>h#$QD$gS|oFAVY%hO_QfF&qhpeTEY|ZP@WTs~+#y
zfVY?hYnO0_eTM2Y%P_2tArbjir(^vhzIxsXX13<%@$LiRx%00M9YiLxB8l_vwnWV|
d8Wra~a3N<=!ntCCIcE|F@Ce&DUh=d-`hQwNYCQk|

diff --git a/spec/.spec_helper.rb.swp b/spec/.spec_helper.rb.swp
deleted file mode 100644
index 1246342965bda0d19fc0e816501ebebf323977e9..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 12288
zcmeI2PmkL~6u_rFfK(_TK%xf@v&+F7(Kzi=6%lC<*^=$9lx(8>Sq^9!jqR6Ys<Fq6
z$0>p3&xtDs1QL7(1SdWK2*GDS9QXoAd;mD`Y=`{=+a*14sPruTGP2*B@tfb+k)lj+
z<6y7LU-fS>Jf30f%J#c&^j`bs@(*i_IVGni35)|hGe!IXM|ZnlkDxv(((9YPmdW{v
zADkJmk=d|uS2-<%#<Xk%HjONWu>24+&?#8o2Ir4PSIGbwcsK)B*(;kjZxnrAT3_SO
zJv)B5?vzai$N(8217v^<kO4A42FSo8ZNR0M*oQcS%gb53ylgN1qg|d-Lk7qI86X2>
zfDDiUGC&5%02v?yWPl7jf(B&7*u5)^Z9aj;<NyDE|Nj5|X~up=enP%SzCyl4K1V)7
zK0++=7IKK(MxIB0dy28|kS`F6bPx}D9C-}+<tmPee2aX72xJ|35xIuEfc*F*V;>_e
z<WH>Y59C+mYvfa8fgB>Yk)rOK2pwdA43GgbKnBPF86X2>;QuiINyIo0O)^naKY)p`
zu+fxS*Z6xJk}S6%GJq)K@1LZpB-D8Xe29VFa$D<3%-9Gl-{PK?Nn~R0Br;LjffY7S
zcynUHJUa>DHG%gO_h*m@n1fxonM$Uj>H-mt=WGsaFvRV&epM`1#v{Xzs<R`;M(yE9
zbjPFCcBd@{?S4=6Tccg<x}!As_l!z5hU0#}HyD+H>wG=VoeVV8Eu_ZB-MZ_wYLNZj
zpxf%KHb!DxJ&^X_gRD}4SM3z8V^epKxuOWK#!i=crv7p!@J@<qMJnBFqr4C)o5&b8
zgxJ}`sf$|eI`@3Pk>zP>Y%w6KR=N7*T!t=}+LyVT87qpud~2&*%>kNdHt(1?R<7A>
zjYqq^f!G;$I%2=oZR3I+ca9;;<n#d@yY1nyb@xoZ!bLpq9(%8!8kMhY@kD975=$4(
z%Jr>^J*w8e+3Xepu$dphL?ytR0f@QODiUE?HTJ=uYVdZh@X58HrBid@-qJ;*SZeR0
zcpfZ7piOX5QlO^GyIqu}W#(2$n<%?d9wecOikG6A=S6phICYB^^8S0I;?-a7T=$N(
z;=5gLYgaBiu7Z21U7R|r9_(TZJoc-eyP=9x4R_4k&z!Ul7kRl%xH@GhG;@!E&HzK0
k1{S{(GXFkEyLLJm)2fii)P%S958m`fgVw>`&^u&*0gcb<CIA2c

-- 
GitLab


From f05627f00a9abf49d1d72ab736aa06efd998caba Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 12:12:18 +0100
Subject: [PATCH 07/46] removes redundant empty line

---
 spec/.blob_spec.rb.swp | Bin 0 -> 24576 bytes
 spec/blob_spec.rb      |   1 -
 2 files changed, 1 deletion(-)
 create mode 100644 spec/.blob_spec.rb.swp

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..18e1c7e9ced827d737cf8ae4a2790989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+M?YB8V9<uqDic_e&U23yE6H#S^nLt}Y%
zIa9mSY@mmPzt^A})avwegU;m`WriKO<!)ghX>Oa~=Lz}ogKHDE)4|Dy#kQ_7o^kb)
zkE@N?pt{~@tZDrEwei{>O^YqI@rKJ845tVN);i^|S0WeJIqkaK__dBBJpRB72`veq
zOuhri{~j7DxCLGtGw+P2+q#apa|1d=z<nm1I3o(}VJkQzy7oyHtsrqZuR28W8%d&y
z_~*4^8>3Sw;;bZvPdhMC*kdeLd3~&p`HC-r>l*LukiqVAY;{=i=(3m4ZL?U+m3Y7=
zOoKOEA_L3M#P;M~H}f~=#4)DGq7`|gY!*4OEs=MM68=HZ$?jWmorrJriHzXZo!cjP
zm+;aRf=F*TqDuD)3<R<yYc-6S?67&q5A%wJPB+v>TVrF1Qy=^EsgK`r>SM=F-SUZ3
zA3uKTmfMEiDK<7ijdM3T{YR$vMgzuXOI<gRiCO#5bZh)7f?jn>Z6xz;oNvHudCR)W
zUkEkuFBdw0J5OjDUIn8yWM#z*qas5=@S3Nm*5^QVVt#4l7*J2syjLlBIm~twCBFZY
zIC1ZZzkK4?z-=eKe&RTJ;^>L5oH%~s8*5eztBv=pXmHZsd$cp3vHf+T>n;Nn!YdUj
zMAV-8GvA-YzDMSNM<+G@9)1u%eEZRR;MHFk3<^e@?o~1T65aNR7Iw!l_Bv~iTRz||
z=FoSEHrU5hpIw7db&QB8cy#_-zl?9sJHb|aaS`u6@bY2TBR`^%c~QiDcRN+H%x1-X
a4?L1yO1U-0iF+k=BaZEk;U&*a(*FWE^rH&^

literal 0
HcmV?d00001

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 969d058..0d89582 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -314,7 +314,6 @@ describe Gitlab::Git::Blob do
       expect(commit.tree.to_a.any? do |tree|
         tree[:name] == 'NEWREADME.md'
       end).to be_truthy
-
     end
   end
 
-- 
GitLab


From 23bd9eb76373b5645ebfa50bbae49e795370c799 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 12:19:58 +0100
Subject: [PATCH 08/46] adds rename action to blob.rb

---
 lib/gitlab_git/.blob.rb.swp | Bin 0 -> 24576 bytes
 lib/gitlab_git/blob.rb      |  35 +++++++++++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)
 create mode 100644 lib/gitlab_git/.blob.rb.swp

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..b08749de7612c6e07c1f48b64a9f5c8238e677ec
GIT binary patch
literal 24576
zcmeI44U8ODeZZ%Q^Wij3(gcM-34Oi;?_P7By$jCQ66fqBHZj=2IU7<qpEq;6v$qrP
z&TMC9eZJTxIH9c+LWKedHzZVPN=4ezs6a&<sima|f*Q3|T2xvE3REo#tq2mPh<>R3
z{ok9}nb|uNyJ=CC%t*i6`FNlI_n-IP|Nq|H!qnS$>{8d*n=FotEbE%>cisLMGmoEf
zbh~B6p0gPE3qkC5JAphu$+7Fk-5Xo(#=R1J<CS*T@mCM{u0n#fC~Vf=<i%ZQp|+@h
z8vN9{Ug2_~8!Xu2!s-c@cS{MB5;!#p4C402Yu8zCxN>?*B8-o%SC?G;wo{8+hAJgc
zN}!ZLDS=V~r36X|loBW<P)gt>A%VER#=4uDoRQS#uH^S8Mt;vqt~VsVhew{TNv>1V
z|05&M&rGhh@xl4Oj66>+%b!vLr36X|loBW<P)eYbKq-Mz0;L2>36v5jB~VJ>|3Csx
z%d*BucY`<pSpQG$|F2$XS$_n72#>?B!3UrZdtesMg3n!GSrKf9pMlrHm)2R<lkjP{
z9~NK>%)p8BE$e&m6#N-H0s-6s6HtX$z<>OtWql2P4?YO*fY-sf@a%b(^%Zy$o`Bzh
zPr&`qf+oBbu7b<p8*44=%kU+55*~#2!#ywun_wOM)47)Q3_K0*g=6q0xD-yDL!R&{
z_$2%y?1$a(R@exWunzwAY-9%^G+{k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Y~NW|6bS+YvEjYn)2TV+h7fxz=r=Gd;#u*BXAhR&c7C33E#zr|2#Ybcf-42
z7PiASSPTD!4gcrx1iT-P!2!4tWKaJZ_&)agGaxqp12BL#?1l|+4*U>%{dxEz9Ebbi
z9ykU~7>DPv-~R!=34a3bg?%s!x4{;89lRP|1?Pe6?f*7B2ghLvX5nIZ4xi4m=|6Fh
zHkG!Qqcm(SEeHOThV4thuq~(gFX1mv%4z<vvr6ai<ut#X=D$3q`8m~J%^WimUA`a_
zpN@F1R-f<k-sGM!L6%GDR~j-m*6!PEa%5%(r#Q1uru*8<YfQi_S#j+S3nZC1*|$;^
zzI7{FrlyR;*c5U%1vJ}%`3f=YX=kwcK1ymiS1<VSa?WR|0G2}foh2VOVb@U4oGe%D
z!!HPOH6e~BC=$=hY}7PMx+tnK#~$^#VO$CMubfgtUMwQx4af!5+vbY`$~`63P`gjW
z7h<y^0aGVeJ0`d%v&&`)FCV0gr4463EY+_1%=F3<FQz)oQwktH1hU7h_StGb$7#NH
zi4mtm6_-0`9b=%SiD=p9GD^kI^PxJd(9x6DuxNRv)s%!@jDC)*tqVcOY6^PgFH?SP
z<*Ftw0Q8JqAjpHyUVT+{ZMN*&cC8%*`Su&ugj&6zVpCZ3IVX})?Lye3Q{gA7b<m%v
zR#8__guJ(9*aEEG<o2wXNW6Tx<a5fJZ$pzy>LoLpQhbiXrSM6dQJh@LCNhB%Z@G9j
z<kRSUGUkqa@~|S9xZZN98TVQ~SmJuig-KirsUyW)&fDyKnc<sES?}kQOw)lR&#eCj
D6{d&6

literal 0
HcmV?d00001

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 94c0307..cb220c0 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -150,6 +150,14 @@ module Gitlab
           if action == :remove
             index.remove(filename)
           else
+            if action == :rename
+              old_path_name = PathHelper.normalize_path(file[:previous_path])
+              raise Repository::InvalidBlobName.new("Invalid path") if path_name.each_filename.to_a.include?('..')
+
+              old_filename = old_path_name.to_s
+              index.remove(old_filename)
+            end
+
             mode = 0o100644
             file_entry = index.get(filename)
 
@@ -207,6 +215,33 @@ module Gitlab
         def remove(repository, options)
           commit(repository, options, :remove)
         end
+
+
+        # Rename file from repository and return commit sha
+        #
+        # options should contain next structure:
+        #   file: {
+        #     previous_path: 'documents/old_story.txt'
+        #     path: 'documents/story.txt'
+        #   },
+        #   author: {
+        #     email: 'user@example.com',
+        #     name: 'Test User',
+        #     time: Time.now
+        #   },
+        #   committer: {
+        #     email: 'user@example.com',
+        #     name: 'Test User',
+        #     time: Time.now
+        #   },
+        #   commit: {
+        #     message: 'Rename FILENAME',
+        #     branch: 'master'
+        #   }
+        #
+        def rename(repository, options)
+          commit(repository, options, :rename)
+        end
       end
 
       def initialize(options)
-- 
GitLab


From 3727fdcfac16459d36561740b39a5415a77801ff Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 12:44:04 +0100
Subject: [PATCH 09/46] fixes accuracy of comments on rename method

---
 lib/gitlab_git/.blob.rb.swp | Bin 24576 -> 24576 bytes
 lib/gitlab_git/blob.rb      |   2 ++
 2 files changed, 2 insertions(+)

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
index b08749de7612c6e07c1f48b64a9f5c8238e677ec..02ca93df3597f403f8fc2553d007f24b33b081d1 100644
GIT binary patch
delta 283
zcmXBPF-t;W6vpxM)=d$KZU`c@NO=h^qJc`#V1aN$qM*g1F|MnM;-Z6o0wG>-Y6x<2
zix*nEOD)>sQbW5CNRwMZ|LDLE4m|L1PCronK*g{3D&^DUekL!BE%JWSxrllX@dH~m
z%(-o{>t6(umH)J1HjkpJHwcTg;NuJqEX+d`;0Z&tafvc=h~RTg<O4H|(M26q`0x<I
z%o2IQGe)T45Cuz$l4sdL7(c5b-&o)cub85XD-^Kg{we<cxYKIexe4yIU2@Gv>Cw{Z
R)Ru0hcJ*z=HH+g|;uq4_G>ZTL

delta 262
zcmXBOze@sf9LDj_x4RSz@p}YEV8e}pa4H6eI;2AW3I`Y4Tf*g5wI!h~Xt6bJYS8ig
zPEO~4&>Dfe4f!|ph8}pq1JClzw`#ss?tN+08+d_#B}9t^?Z>;%>)5Sn6`G+o#cW-P
z<gEWSG*07GJuTBB3yjf40T;0Fof6sL9j};R03RM)9F9d27_6|w3;J+zf(-Vy$QsX>
vVTuP^DsoF{qJc8<aG;U!HNp&4XymLoZYlFK{5mopH#_wfjV{e^=j{9sem5$1

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index cb220c0..390bfb6 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -223,6 +223,8 @@ module Gitlab
         #   file: {
         #     previous_path: 'documents/old_story.txt'
         #     path: 'documents/story.txt'
+        #     content: 'Lorem ipsum...',
+        #     update: true
         #   },
         #   author: {
         #     email: 'user@example.com',
-- 
GitLab


From b2a2273b83b9511ea94d36b2bb60592a4693078a Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 14:36:22 +0100
Subject: [PATCH 10/46] fixes bug regarding old_path_name in blob.rb's commit
 method

---
 lib/gitlab_git/blob.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 390bfb6..c6a902c 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -152,7 +152,7 @@ module Gitlab
           else
             if action == :rename
               old_path_name = PathHelper.normalize_path(file[:previous_path])
-              raise Repository::InvalidBlobName.new("Invalid path") if path_name.each_filename.to_a.include?('..')
+              raise Repository::InvalidBlobName.new("Invalid path") if old_path_name.each_filename.to_a.include?('..')
 
               old_filename = old_path_name.to_s
               index.remove(old_filename)
-- 
GitLab


From 95b684a3fec790dbcea16ae1a44a97e21e113bee Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 10:38:09 +0100
Subject: [PATCH 11/46] removes .swp file

---
 lib/gitlab_git/.blob.rb.swp | Bin 24576 -> 0 bytes
 lib/gitlab_git/blob.rb      |   2 --
 2 files changed, 2 deletions(-)
 delete mode 100644 lib/gitlab_git/.blob.rb.swp

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
deleted file mode 100644
index 02ca93df3597f403f8fc2553d007f24b33b081d1..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 24576
zcmeI44U8ODeZZ%Q^I?cXl^_VHq0e{3yI0P$=fn=lHqO~eY+`VNb2bEWK5yoBXKyFo
zo!QRJ`h2lXa6(%NQiQ^n8%WzUPzhQZ6{x5p^^4LFgj-c<5vc?esM>t=!$>$qw4nC)
ze{W`IX73!^O<PrAM*7{($D8-@fB$*&{{R1*o1c37j$70l?Tr@OPg~YgZ@K&Smv4Xc
zoFm&UEB2g)z@HCdx7!Ki`YE<sZrHWH<*wf&$=6?LcO8G_gzqY3Sc}4D?M+_Xb>?de
z`lrE9t?LyI=exnY9nP<uVR^QcKq-MUlfWQuufJxEb=8#{rsRh4v9;>bOWt;7_m-(j
z36v5jB~VJBlt3wgQUav}N(qz_cu7bg?ys`$p(W=et+_k-{i%`P^OECr$?u_&>#LIE
ze)9XVk?ZFs$J+Q{|DQ*$Cx_)vDS=V~r36X|loBW<P)eYbKq-Mz0;L2>36v5jCGfu>
z0jFhIW8}L|900`sQ~Up$udu8?f<J^u;Wy!f(1+bH1LwgPFSe`*w!_cD>)<PEEb9sQ
zJlqfSumz^!<VBYCeK-zZg@+-4J7EH<@Jjg6%Ps3$@cZx~cqhCbE`(=Z#ySOf0v?0k
zh0nnK(1Iqs6*j?T@SW9`^)>hkJOK~F2jE_qg^jQV{_#S~`UX4+?}MZ8CU_N`ynr&{
zbMRUCCD;eM;H|J8CSeWy?f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`zyiD(B)0!J_Wpy=g`1%c*TQSz
z2iW<~z?WeO&WH2hYt-v^;Nu{56x;tk*axfOLU@w;zZbT_DmaM^|9yBI-V2A}5Qv?B
z4ZIq@haLYVco^=1cfky7hi$ML{u4X?FX1ux033z=a0AGi{#EciHoVyRpMwWr0BzU>
z>)-<TA@=(T_%a-W`{7<V3QZ6j{{;5?-@|v|PvL#A7iQo#*aEMI*TQSyWgu(&pMz)N
z7%ajJTmsMX4;-FJ|A~Y2sr0>UrEzR&Iq;`6j$Z=CaXHO@34d`?PV<L@RXT?+r}^bH
z|0iRbpHuyn%rP_3<qI<L>4^7g<@qkpP3{^KWI5EUWMyuwUBKDo$jl7RaAu!O_qC_k
zn1ETf;vODWND6VXZ>1`H>sGW(O&y1KQ^{Q{<2B2H`3f=YX@|1;K1y0STQB(Wat>^1
z0G2}foh2VOVb{>koGh2E!!HPOB_WPxC=$=hY}7PMhA5gb%Nq5#VO$CMubfgtUMwQx
z4ag<b%jSy$%3USbP`gjW7h<y@0aGW}IwrWMvdd;jFCV0gr5$HJEY<G*%=F4KFXlQd
zQz{@n1d7M3_E~B_%Wl4Pi4mt$6+<TUjxo^EOtkEC1*PKW`cNH~>F6n2ShPITW=cjc
zMnA{Z*7+bLB7<J}OVnRmxvGf^06k+B2=d^wS6@|Kn<e|UU26wHzW;_Tp;f0<Y$}UB
z=R`89T?m_eD*QyX4*C<-D(VeXA@6M&_5ksp+?o}06Axc5`<$}o`_Pn<ddZBY6tClO
zDSQ%V6epLnxtT<Xw_H3M@@aHF8*@fJd03WATyMGDjC(DgEOEW%(j+d0)RAHi=WJHK
TO!G~q#QXUq(+nWVHS50s-n_1q

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index c6a902c..52d1138 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -152,8 +152,6 @@ module Gitlab
           else
             if action == :rename
               old_path_name = PathHelper.normalize_path(file[:previous_path])
-              raise Repository::InvalidBlobName.new("Invalid path") if old_path_name.each_filename.to_a.include?('..')
-
               old_filename = old_path_name.to_s
               index.remove(old_filename)
             end
-- 
GitLab


From 4caf1ff3e0be2adc27259d792e3412d37dcacf26 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 11:23:23 +0100
Subject: [PATCH 12/46] adds tests for renaming a file

---
 spec/.blob_snippet_spec.rb.swp | Bin 0 -> 12288 bytes
 spec/.blob_spec.rb.swp         | Bin 0 -> 28672 bytes
 spec/.spec_helper.rb.swp       | Bin 0 -> 12288 bytes
 spec/blob_spec.rb              |  48 +++++++++++++++++++++++++++++++++
 4 files changed, 48 insertions(+)
 create mode 100644 spec/.blob_snippet_spec.rb.swp
 create mode 100644 spec/.blob_spec.rb.swp
 create mode 100644 spec/.spec_helper.rb.swp

diff --git a/spec/.blob_snippet_spec.rb.swp b/spec/.blob_snippet_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..ddfee16af275096b2c18d97b3a746bd6d8f4ad99
GIT binary patch
literal 12288
zcmeI2&uY|A6vl50ZiK4X7dVZJ%)m_28HLv1Y8DlRf?%r)m5@J&nLy^=G`VG}qV0?L
z4B|WZ0Iqc9Bj^(-cy1@--xdq5D&K`KC%HNI%elX-LQcB=;LbK}1UHn7D@t7)J$txy
z^Y!xEHKlBkjEzo><#J-&{Zq#F=w3hP{*FuU4}&t%CnvuA#V~B@EWBOVGD*Ynafl^^
zO~qN5mL`oGT~rm@*v$lWda@^GK>!5KN?=7@9}d=C_BC&fR<G`!bs_RV00ck)1V8`;
zKmY_l00jO60=8OGhq905b}y@KT>34xmk1yL0w4eaAOHd&00JNY0w4eaAOHgAkU)|v
z^=?I}%}Y|e{QqBk|9`%$)F;sg(R<Mw(JRrBXeb(pE{ML$x-X)Sq9f6v=&ooax+QYH
z8zKx4009sH0T2KI5C8!X009sHf%8d#b*_l!#~+cXu=JexKw7qKr)}U4^28?Hz#8Jc
zjyE&2$9lS-O}s9>P~zc6$+i=<>0L3Hw}nTM#3&j`Gx+^^FL<DN*72uFW4ZQw^vD-C
ziN5pmpY&)T=Q1VT;=Xft)|t_k4=njr%?)cyWudw8DL3<nFShWP(o>FgQT}tq;?bkU
z;g1q|TG^*R6-bnGlhsAa6gh~l=<hS9F*@E^&3pSr&E&b}`FO%*#kD70zw*X1lNWj%
L(eBPxe^Y$}9_PtW

literal 0
HcmV?d00001

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..55948ef86f930d92ca44f0f38400a5a9ba0df0cd
GIT binary patch
literal 28672
zcmeI44~!gFea9y$32jOeFltKDQa$fU-7`M#?f-vCNY3^F4nEsGpD}T;wzD&D@5bJp
zS!QN^w{aXp0wJV?icmx)TH3@hL=cjo6a|w4{SyePigPKDsDXltBM=b@g3utOM(y|a
z=I{Q!J^LIIG%I~>_h#O_dGGgr@6Ye|elykNJGRZRLLw{S^IAzda@*m(w~s$??j!3Z
z$=2j~L$4Y(uP+#Me!ypD^R7)Q-!w<bH>DGGS?{0l#*PdpEmN6%t7g~b>g2rms^DwV
zYI0?=S~sc{`js%N{qu^BMiPi5unGyZ?AoT{g;FM+O43zhvGwfr>-MZ7gD7bvfk*<8
z1R@DU5{M)aNg$FyB!Nf*uXG96&GV$AsKmK$MY#KYPS^MO?*E=?U+X&mD);}o`~B^%
z^XIw$zuEm>=ib1(&+oX$%kKA%uJi8U=qr*yB!Nf*kpv<ML=uQ35J@1CKqP@k0+9qF
z2}BY&4GGAqB>e%d`x@EX*#GzJ|K~22q-VjC;0f?W&;mBt2gX1QoCkhzktF>ixC7h<
z-Un_52G|LnxlodR0`3C_$bjcxBT2_V8(af6gDEfu9{qhu`Z`zyTfytV;}=NM$G|~w
z1;~O7I2RoMJxRJ7>;W<Gv)`4Z`+)_vfy=-;@H+7GS0f+rSD*<Nz&v;xcpgrUUw~ua
zde8=&!DZkDI52(+o(8ADqu`yO0P^5`@EDvR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CCDsE)9jm_he0_N?;AfEhkXI
zTmQtCk1v1a@%MmRm%q4tf<6Ae<p-8eEI&N5T9_@oXGQj(^mnUv`aQP4PITR6fI_&b
z0)+^Vr(VzZI<dF#^uEKL8o!4>h#$QD$gS|oFAVY%hO_QfF&qhpeTEY|ZP@WTs~+#y
zfVY?hYnO0_eTM2Y%P_2tArbjir(^vhzIxsXX13<%@$LiRx%00M9YiLxB8l_vwnWV|
d8Wra~a3N<=!ntCCIcE|F@Ce&DUh=d-`hQwNYCQk|

literal 0
HcmV?d00001

diff --git a/spec/.spec_helper.rb.swp b/spec/.spec_helper.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..1246342965bda0d19fc0e816501ebebf323977e9
GIT binary patch
literal 12288
zcmeI2PmkL~6u_rFfK(_TK%xf@v&+F7(Kzi=6%lC<*^=$9lx(8>Sq^9!jqR6Ys<Fq6
z$0>p3&xtDs1QL7(1SdWK2*GDS9QXoAd;mD`Y=`{=+a*14sPruTGP2*B@tfb+k)lj+
z<6y7LU-fS>Jf30f%J#c&^j`bs@(*i_IVGni35)|hGe!IXM|ZnlkDxv(((9YPmdW{v
zADkJmk=d|uS2-<%#<Xk%HjONWu>24+&?#8o2Ir4PSIGbwcsK)B*(;kjZxnrAT3_SO
zJv)B5?vzai$N(8217v^<kO4A42FSo8ZNR0M*oQcS%gb53ylgN1qg|d-Lk7qI86X2>
zfDDiUGC&5%02v?yWPl7jf(B&7*u5)^Z9aj;<NyDE|Nj5|X~up=enP%SzCyl4K1V)7
zK0++=7IKK(MxIB0dy28|kS`F6bPx}D9C-}+<tmPee2aX72xJ|35xIuEfc*F*V;>_e
z<WH>Y59C+mYvfa8fgB>Yk)rOK2pwdA43GgbKnBPF86X2>;QuiINyIo0O)^naKY)p`
zu+fxS*Z6xJk}S6%GJq)K@1LZpB-D8Xe29VFa$D<3%-9Gl-{PK?Nn~R0Br;LjffY7S
zcynUHJUa>DHG%gO_h*m@n1fxonM$Uj>H-mt=WGsaFvRV&epM`1#v{Xzs<R`;M(yE9
zbjPFCcBd@{?S4=6Tccg<x}!As_l!z5hU0#}HyD+H>wG=VoeVV8Eu_ZB-MZ_wYLNZj
zpxf%KHb!DxJ&^X_gRD}4SM3z8V^epKxuOWK#!i=crv7p!@J@<qMJnBFqr4C)o5&b8
zgxJ}`sf$|eI`@3Pk>zP>Y%w6KR=N7*T!t=}+LyVT87qpud~2&*%>kNdHt(1?R<7A>
zjYqq^f!G;$I%2=oZR3I+ca9;;<n#d@yY1nyb@xoZ!bLpq9(%8!8kMhY@kD975=$4(
z%Jr>^J*w8e+3Xepu$dphL?ytR0f@QODiUE?HTJ=uYVdZh@X58HrBid@-qJ;*SZeR0
zcpfZ7piOX5QlO^GyIqu}W#(2$n<%?d9wecOikG6A=S6phICYB^^8S0I;?-a7T=$N(
z;=5gLYgaBiu7Z21U7R|r9_(TZJoc-eyP=9x4R_4k&z!Ul7kRl%xH@GhG;@!E&HzK0
k1{S{(GXFkEyLLJm)2fii)P%S958m`fgVw>`&^u&*0gcb<CIA2c

literal 0
HcmV?d00001

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 6998ea3..969d058 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -270,6 +270,54 @@ describe Gitlab::Git::Blob do
     end
   end
 
+  describe :rename do
+    let(:repository) { Gitlab::Git::Repository.new(TEST_NORMAL_REPO_PATH) }
+
+    let(:commit_options) do
+      options = {
+        file: {
+          path: 'NEWREADME.md',
+          previous_path: 'README.md',
+          content: 'Lorem ipsum...',
+          update: true
+        },
+        author: {
+          email: 'user@example.com',
+          name: 'Test User',
+          time: Time.now
+        },
+        committer: {
+          email: 'user@example.com',
+          name: 'Test User',
+          time: Time.now
+        },
+        commit: {
+          message: 'Rename readme',
+          branch: 'master'
+        }
+      }
+    end
+
+    let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
+    let!(:commit) { repository.lookup(commit_sha) }
+
+    it 'should rename the file with commit' do
+      # Commit message valid
+      expect(commit.message).to eq('Rename readme')
+
+      # Previous file was removed
+      expect(commit.tree.to_a.any? do |tree|
+        tree[:name] == 'README.md'
+      end).to be_falsey
+
+      # File was renamed
+      expect(commit.tree.to_a.any? do |tree|
+        tree[:name] == 'NEWREADME.md'
+      end).to be_truthy
+
+    end
+  end
+
   describe :remove do
     let(:repository) { Gitlab::Git::Repository.new(TEST_REPO_PATH) }
 
-- 
GitLab


From 9a5634db1442099c41c7c26e78aad75b995b8d3b Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 12:11:28 +0100
Subject: [PATCH 13/46] removes swp files

---
 spec/.blob_snippet_spec.rb.swp | Bin 12288 -> 0 bytes
 spec/.blob_spec.rb.swp         | Bin 28672 -> 0 bytes
 spec/.spec_helper.rb.swp       | Bin 12288 -> 0 bytes
 3 files changed, 0 insertions(+), 0 deletions(-)
 delete mode 100644 spec/.blob_snippet_spec.rb.swp
 delete mode 100644 spec/.blob_spec.rb.swp
 delete mode 100644 spec/.spec_helper.rb.swp

diff --git a/spec/.blob_snippet_spec.rb.swp b/spec/.blob_snippet_spec.rb.swp
deleted file mode 100644
index ddfee16af275096b2c18d97b3a746bd6d8f4ad99..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 12288
zcmeI2&uY|A6vl50ZiK4X7dVZJ%)m_28HLv1Y8DlRf?%r)m5@J&nLy^=G`VG}qV0?L
z4B|WZ0Iqc9Bj^(-cy1@--xdq5D&K`KC%HNI%elX-LQcB=;LbK}1UHn7D@t7)J$txy
z^Y!xEHKlBkjEzo><#J-&{Zq#F=w3hP{*FuU4}&t%CnvuA#V~B@EWBOVGD*Ynafl^^
zO~qN5mL`oGT~rm@*v$lWda@^GK>!5KN?=7@9}d=C_BC&fR<G`!bs_RV00ck)1V8`;
zKmY_l00jO60=8OGhq905b}y@KT>34xmk1yL0w4eaAOHd&00JNY0w4eaAOHgAkU)|v
z^=?I}%}Y|e{QqBk|9`%$)F;sg(R<Mw(JRrBXeb(pE{ML$x-X)Sq9f6v=&ooax+QYH
z8zKx4009sH0T2KI5C8!X009sHf%8d#b*_l!#~+cXu=JexKw7qKr)}U4^28?Hz#8Jc
zjyE&2$9lS-O}s9>P~zc6$+i=<>0L3Hw}nTM#3&j`Gx+^^FL<DN*72uFW4ZQw^vD-C
ziN5pmpY&)T=Q1VT;=Xft)|t_k4=njr%?)cyWudw8DL3<nFShWP(o>FgQT}tq;?bkU
z;g1q|TG^*R6-bnGlhsAa6gh~l=<hS9F*@E^&3pSr&E&b}`FO%*#kD70zw*X1lNWj%
L(eBPxe^Y$}9_PtW

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
deleted file mode 100644
index 55948ef86f930d92ca44f0f38400a5a9ba0df0cd..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 28672
zcmeI44~!gFea9y$32jOeFltKDQa$fU-7`M#?f-vCNY3^F4nEsGpD}T;wzD&D@5bJp
zS!QN^w{aXp0wJV?icmx)TH3@hL=cjo6a|w4{SyePigPKDsDXltBM=b@g3utOM(y|a
z=I{Q!J^LIIG%I~>_h#O_dGGgr@6Ye|elykNJGRZRLLw{S^IAzda@*m(w~s$??j!3Z
z$=2j~L$4Y(uP+#Me!ypD^R7)Q-!w<bH>DGGS?{0l#*PdpEmN6%t7g~b>g2rms^DwV
zYI0?=S~sc{`js%N{qu^BMiPi5unGyZ?AoT{g;FM+O43zhvGwfr>-MZ7gD7bvfk*<8
z1R@DU5{M)aNg$FyB!Nf*uXG96&GV$AsKmK$MY#KYPS^MO?*E=?U+X&mD);}o`~B^%
z^XIw$zuEm>=ib1(&+oX$%kKA%uJi8U=qr*yB!Nf*kpv<ML=uQ35J@1CKqP@k0+9qF
z2}BY&4GGAqB>e%d`x@EX*#GzJ|K~22q-VjC;0f?W&;mBt2gX1QoCkhzktF>ixC7h<
z-Un_52G|LnxlodR0`3C_$bjcxBT2_V8(af6gDEfu9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QJJ{~*u-jANT=|iX9d;h7M
zZ#i|-iBmV<I_ypzZR20DcCFLDWqNNkpl!A+XgVS>MsJ#KjbA~~D|V?dHrqmkCtl05
zs44V9C>?)E==63Tp=o#(j9kMeuN!BE2nB}MJh^JU2CCDsE)9jm_he0_N?;AfEhkXI
zTmQtCk1v1a@%MmRm%q4tf<6Ae<p-8eEI&N5T9_@oXGQj(^mnUv`aQP4PITR6fI_&b
z0)+^Vr(VzZI<dF#^uEKL8o!4>h#$QD$gS|oFAVY%hO_QfF&qhpeTEY|ZP@WTs~+#y
zfVY?hYnO0_eTM2Y%P_2tArbjir(^vhzIxsXX13<%@$LiRx%00M9YiLxB8l_vwnWV|
d8Wra~a3N<=!ntCCIcE|F@Ce&DUh=d-`hQwNYCQk|

diff --git a/spec/.spec_helper.rb.swp b/spec/.spec_helper.rb.swp
deleted file mode 100644
index 1246342965bda0d19fc0e816501ebebf323977e9..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 12288
zcmeI2PmkL~6u_rFfK(_TK%xf@v&+F7(Kzi=6%lC<*^=$9lx(8>Sq^9!jqR6Ys<Fq6
z$0>p3&xtDs1QL7(1SdWK2*GDS9QXoAd;mD`Y=`{=+a*14sPruTGP2*B@tfb+k)lj+
z<6y7LU-fS>Jf30f%J#c&^j`bs@(*i_IVGni35)|hGe!IXM|ZnlkDxv(((9YPmdW{v
zADkJmk=d|uS2-<%#<Xk%HjONWu>24+&?#8o2Ir4PSIGbwcsK)B*(;kjZxnrAT3_SO
zJv)B5?vzai$N(8217v^<kO4A42FSo8ZNR0M*oQcS%gb53ylgN1qg|d-Lk7qI86X2>
zfDDiUGC&5%02v?yWPl7jf(B&7*u5)^Z9aj;<NyDE|Nj5|X~up=enP%SzCyl4K1V)7
zK0++=7IKK(MxIB0dy28|kS`F6bPx}D9C-}+<tmPee2aX72xJ|35xIuEfc*F*V;>_e
z<WH>Y59C+mYvfa8fgB>Yk)rOK2pwdA43GgbKnBPF86X2>;QuiINyIo0O)^naKY)p`
zu+fxS*Z6xJk}S6%GJq)K@1LZpB-D8Xe29VFa$D<3%-9Gl-{PK?Nn~R0Br;LjffY7S
zcynUHJUa>DHG%gO_h*m@n1fxonM$Uj>H-mt=WGsaFvRV&epM`1#v{Xzs<R`;M(yE9
zbjPFCcBd@{?S4=6Tccg<x}!As_l!z5hU0#}HyD+H>wG=VoeVV8Eu_ZB-MZ_wYLNZj
zpxf%KHb!DxJ&^X_gRD}4SM3z8V^epKxuOWK#!i=crv7p!@J@<qMJnBFqr4C)o5&b8
zgxJ}`sf$|eI`@3Pk>zP>Y%w6KR=N7*T!t=}+LyVT87qpud~2&*%>kNdHt(1?R<7A>
zjYqq^f!G;$I%2=oZR3I+ca9;;<n#d@yY1nyb@xoZ!bLpq9(%8!8kMhY@kD975=$4(
z%Jr>^J*w8e+3Xepu$dphL?ytR0f@QODiUE?HTJ=uYVdZh@X58HrBid@-qJ;*SZeR0
zcpfZ7piOX5QlO^GyIqu}W#(2$n<%?d9wecOikG6A=S6phICYB^^8S0I;?-a7T=$N(
z;=5gLYgaBiu7Z21U7R|r9_(TZJoc-eyP=9x4R_4k&z!Ul7kRl%xH@GhG;@!E&HzK0
k1{S{(GXFkEyLLJm)2fii)P%S958m`fgVw>`&^u&*0gcb<CIA2c

-- 
GitLab


From b9635e2d3d029bc7d782dd33efac708f10fcf4a2 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 12:12:18 +0100
Subject: [PATCH 14/46] removes redundant empty line

---
 spec/.blob_spec.rb.swp | Bin 0 -> 24576 bytes
 spec/blob_spec.rb      |   1 -
 2 files changed, 1 deletion(-)
 create mode 100644 spec/.blob_spec.rb.swp

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..18e1c7e9ced827d737cf8ae4a2790989f9456be1
GIT binary patch
literal 24576
zcmeI34Uingb;rjTa2$iNaoI6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Pzt^A})avwegU;m`WriKO<!)ghX>Oa~=Lz}ogKHDE)4|Dy#kQ_7o^kb)
zkE@N?pt{~@tZDrEwei{>O^YqI@rKJ845tVN);i^|S0WeJIqkaK__dBBJpRB72`veq
zOuhri{~j7DxCLGtGw+P2+q#apa|1d=z<nm1I3o(}VJkQzy7oyHtsrqZuR28W8%d&y
z_~*4^8>3Sw;;bZvPdhMC*kdeLd3~&p`HC-r>l*LukiqVAY;{=i=(3m4ZL?U+m3Y7=
zOoKOEA_L3M#P;M~H}f~=#4)DGq7`|gY!*4OEs=MM68=HZ$?jWmorrJriHzXZo!cjP
zm+;aRf=F*TqDuD)3<R<yYc-6S?67&q5A%wJPB+v>TVrF1Qy=^EsgK`r>SM=F-SUZ3
zA3uKTmfMEiDK<7ijdM3T{YR$vMgzuXOI<gRiCO#5bZh)7f?jn>Z6xz;oNvHudCR)W
zUkEkuFBdw0J5OjDUIn8yWM#z*qas5=@S3Nm*5^QVVt#4l7*J2syjLlBIm~twCBFZY
zIC1ZZzkK4?z-=eKe&RTJ;^>L5oH%~s8*5eztBv=pXmHZsd$cp3vHf+T>n;Nn!YdUj
zMAV-8GvA-YzDMSNM<+G@9)1u%eEZRR;MHFk3<^e@?o~1T65aNR7Iw!l_Bv~iTRz||
z=FoSEHrU5hpIw7db&QB8cy#_-zl?9sJHb|aaS`u6@bY2TBR`^%c~QiDcRN+H%x1-X
a4?L1yO1U-0iF+k=BaZEk;U&*a(*FWE^rH&^

literal 0
HcmV?d00001

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 969d058..0d89582 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -314,7 +314,6 @@ describe Gitlab::Git::Blob do
       expect(commit.tree.to_a.any? do |tree|
         tree[:name] == 'NEWREADME.md'
       end).to be_truthy
-
     end
   end
 
-- 
GitLab


From 982c3e7052903f3946e901c824ded94c68645fc4 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 15:02:21 +0100
Subject: [PATCH 15/46] removes .swp file

---
 spec/.blob_spec.rb.swp | Bin 24576 -> 0 bytes
 1 file changed, 0 insertions(+), 0 deletions(-)
 delete mode 100644 spec/.blob_spec.rb.swp

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
deleted file mode 100644
index 18e1c7e9ced827d737cf8ae4a2790989f9456be1..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 24576
zcmeI34Uingb;rjTa2$iNaoI6APPJB5*^{~3o7wMOn}U<>h~?Z#^66wDVP(@h(|bE;
zcV?NHy}LzUu@MfTATHy?NyYiH0h?fqOeHQ`F$qa*hon*kA|_B#oT411utOPAMm8y`
z;!6JA^SxhpCkX+`Zq-kF+Uf4;dHwqJd#`({@<+DLkwPjf;qx|0I&}Mi-FJ?C<$_;O
zB+1d~qG?o3hc)UZzdqnIw|U2e#wHec@riV*L5=<e562puv@Lb=mvpB=tCNf3tAejd
zyT#PWYQwBn_+Kfj+P|&QuOkVJB(M$%w4K^S@lq+1R%BjlV`2k&$K|`$(ZHzaNCG1X
zj3h9Uz(@ik35+B#lE6p;BMH3TCE&C!l#bvbF7O_NdEam7`o75fzaQGyx~^a7{r^_)
z`^m2BZ}k5EE8h2B?*{&Tyq`y3BMFQoFp|JX0wW2GBruY|NCG1Xj3h9Uz(@ik35+E0
z3P^xzlJrir`)wYGWB=ce|6jOFlAZ@ogQvjPK^r(=FW3kY;3DwMTP5jXa2L2890j)k
z6Kn_1T`Ecc0UiV<$bi$ANYdS)13m;cgDJ2PJo*+%`dhFJror366F)0SzYX?-4}dJl
zfD6FAZ<eHcz%Gyg|M@eLbPU*FE4UI|4&Dxa^d__eehaif9V~(mg3}jE(u?43a5LzD
z&EQJ#5)vRk1pf|Bfk(mhpaAmVV(>VUAdi8&!EP`IX2CeP5d0&OAb$t`3j8@Z4!!_(
zfp>$GNWwe_ZU!B&4@`m=FgARAzBMRWLcCA4U8^yRT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WE^rH&^

-- 
GitLab


From 4bb6289cef140d4b2579d9cd2a0779f1f47797dc Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 10:58:16 +0100
Subject: [PATCH 16/46] adds new test for rename method and refactors code for
 the test

---
 CHANGELOG         |  1 +
 spec/blob_spec.rb | 34 +++++++++++++++++++++++++---------
 2 files changed, 26 insertions(+), 9 deletions(-)

diff --git a/CHANGELOG b/CHANGELOG
index 6c97ded..faccc8a 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,5 +1,6 @@
 v 10.3.0 (unreleased)
   - Remove Repository#format_patch
+	- Rename a repository file
 
 v 10.2.3
   - Handle nil blob data
diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 0d89582..42d6e58 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -298,22 +298,35 @@ describe Gitlab::Git::Blob do
       }
     end
 
+    let!(:ref) { commit_options[:commit][:branch] }
+    let!(:prev_commit_count) { repository.commit_count(ref) }
     let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
+    let!(:commit_count) { repository.commit_count(ref) }
+    let!(:blob) {
+      commit.tree.to_a.any? do |tree|
+        tree[:name] == 'NEWREADME.md'
+      end
+    }
+
+    let!(:previous_blob) {
+      commit.tree.to_a.any? do |tree|
+        tree[:name] == 'README.md'
+      end
+    }
 
     it 'should rename the file with commit' do
       # Commit message valid
       expect(commit.message).to eq('Rename readme')
 
+      #Only one commit was made
+      expect(commit_count).to eq(prev_commit_count + 1)
+
       # Previous file was removed
-      expect(commit.tree.to_a.any? do |tree|
-        tree[:name] == 'README.md'
-      end).to be_falsey
+      expect(previous_blob).to be_falsey
 
       # File was renamed
-      expect(commit.tree.to_a.any? do |tree|
-        tree[:name] == 'NEWREADME.md'
-      end).to be_truthy
+      expect(blob).to be_truthy
     end
   end
 
@@ -344,15 +357,18 @@ describe Gitlab::Git::Blob do
 
     let!(:commit_sha) { Gitlab::Git::Blob.remove(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
+    let!(:blob) {
+      commit.tree.to_a.any? do |tree|
+        tree[:name] == "README.md"
+      end
+    }
 
     it 'should remove file with commit' do
       # Commit message valid
       expect(commit.message).to eq('Remove readme')
 
       # File was removed
-      expect(commit.tree.to_a.any? do |tree|
-        tree[:name] == 'README.md'
-      end).to be_falsey
+      expect(blob).to be_falsey
     end
   end
 
-- 
GitLab


From cfb423fb576590525c4a978bc21cc98917c3334c Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 10:59:29 +0100
Subject: [PATCH 17/46] changes tabs to spaces on CHANGELOG file

---
 CHANGELOG | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/CHANGELOG b/CHANGELOG
index faccc8a..79567d5 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,6 +1,6 @@
 v 10.3.0 (unreleased)
   - Remove Repository#format_patch
-	- Rename a repository file
+  - Rename a repository file
 
 v 10.2.3
   - Handle nil blob data
-- 
GitLab


From 532164b1469d655da61d897a0a9fcf8c9692d4cd Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 15:01:53 +0100
Subject: [PATCH 18/46] improves codestyle of test

---
 spec/blob_spec.rb | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 42d6e58..f5f372b 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -299,10 +299,8 @@ describe Gitlab::Git::Blob do
     end
 
     let!(:ref) { commit_options[:commit][:branch] }
-    let!(:prev_commit_count) { repository.commit_count(ref) }
     let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
-    let!(:commit_count) { repository.commit_count(ref) }
     let!(:blob) {
       commit.tree.to_a.any? do |tree|
         tree[:name] == 'NEWREADME.md'
@@ -319,8 +317,8 @@ describe Gitlab::Git::Blob do
       # Commit message valid
       expect(commit.message).to eq('Rename readme')
 
-      #Only one commit was made
-      expect(commit_count).to eq(prev_commit_count + 1)
+      # Only one commit was made
+      expect(commit_sha).to change { repository.commit_count(ref) }.by(1)
 
       # Previous file was removed
       expect(previous_blob).to be_falsey
-- 
GitLab


From e81f688bbf11bc75d23469c41d5b1573fc30bdec Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 15:16:33 +0100
Subject: [PATCH 19/46] reverts back to old codestyle for rename test

---
 spec/blob_spec.rb | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index f5f372b..42d6e58 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -299,8 +299,10 @@ describe Gitlab::Git::Blob do
     end
 
     let!(:ref) { commit_options[:commit][:branch] }
+    let!(:prev_commit_count) { repository.commit_count(ref) }
     let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
+    let!(:commit_count) { repository.commit_count(ref) }
     let!(:blob) {
       commit.tree.to_a.any? do |tree|
         tree[:name] == 'NEWREADME.md'
@@ -317,8 +319,8 @@ describe Gitlab::Git::Blob do
       # Commit message valid
       expect(commit.message).to eq('Rename readme')
 
-      # Only one commit was made
-      expect(commit_sha).to change { repository.commit_count(ref) }.by(1)
+      #Only one commit was made
+      expect(commit_count).to eq(prev_commit_count + 1)
 
       # Previous file was removed
       expect(previous_blob).to be_falsey
-- 
GitLab


From a7b5c0511a96824baeb70ebf08f42e820c3a74e1 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 16:47:34 +0100
Subject: [PATCH 20/46] fixes issues for MR acceptance

---
 spec/blob_spec.rb | 29 ++++++++++-------------------
 1 file changed, 10 insertions(+), 19 deletions(-)

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 42d6e58..7f4bb00 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -300,33 +300,24 @@ describe Gitlab::Git::Blob do
 
     let!(:ref) { commit_options[:commit][:branch] }
     let!(:prev_commit_count) { repository.commit_count(ref) }
-    let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
-    let!(:commit) { repository.lookup(commit_sha) }
-    let!(:commit_count) { repository.commit_count(ref) }
-    let!(:blob) {
-      commit.tree.to_a.any? do |tree|
-        tree[:name] == 'NEWREADME.md'
-      end
-    }
-
-    let!(:previous_blob) {
-      commit.tree.to_a.any? do |tree|
-        tree[:name] == 'README.md'
-      end
-    }
+    let(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
+    let(:commit_count) { repository.commit_count(ref) }
+    let(:commit) { repository.lookup(commit_sha) }
+    let(:blob) { Gitlab::Git::Blob.find(repository, commit_sha, "NEWREADME.md") }
+    let(:removed_blob) { Gitlab::Git::Blob.find(repository, commit_sha, "README.md") }
 
     it 'should rename the file with commit' do
       # Commit message valid
       expect(commit.message).to eq('Rename readme')
 
-      #Only one commit was made
+      # Only one commit was made
       expect(commit_count).to eq(prev_commit_count + 1)
 
       # Previous file was removed
-      expect(previous_blob).to be_falsey
+      expect(removed_blob).to be_nil
 
       # File was renamed
-      expect(blob).to be_truthy
+      expect(blob).not_to be_nil
     end
   end
 
@@ -357,11 +348,11 @@ describe Gitlab::Git::Blob do
 
     let!(:commit_sha) { Gitlab::Git::Blob.remove(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
-    let!(:blob) {
+    let!(:blob) do
       commit.tree.to_a.any? do |tree|
         tree[:name] == "README.md"
       end
-    }
+    end
 
     it 'should remove file with commit' do
       # Commit message valid
-- 
GitLab


From d0610a397e7a6a95b6984157cfccbc1dfeb5c100 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 16:52:38 +0100
Subject: [PATCH 21/46] adds rubocop-rspec gem

---
 Gemfile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Gemfile b/Gemfile
index 038a3e8..5a896d3 100644
--- a/Gemfile
+++ b/Gemfile
@@ -4,6 +4,7 @@ gemspec
 
 group :development do
   gem 'rubocop'
+  gem 'rubocop-rspec' '~> 1.5.0'
   gem 'coveralls', require: false
   gem 'rspec', '~> 3.0'
   gem 'rspec-mocks'
-- 
GitLab


From 042da0e2b39c5bbb131370c910cf0d037762399d Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 16:54:50 +0100
Subject: [PATCH 22/46] fixes :remove test for remove action

---
 spec/blob_spec.rb | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 7f4bb00..0af42c9 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -346,20 +346,16 @@ describe Gitlab::Git::Blob do
       }
     end
 
-    let!(:commit_sha) { Gitlab::Git::Blob.remove(repository, commit_options) }
-    let!(:commit) { repository.lookup(commit_sha) }
-    let!(:blob) do
-      commit.tree.to_a.any? do |tree|
-        tree[:name] == "README.md"
-      end
-    end
+    let(:commit_sha) { Gitlab::Git::Blob.remove(repository, commit_options) }
+    let(:commit) { repository.lookup(commit_sha) }
+    let(:blob) { Gitlab::Git::Blob.find(repository, commit_sha, "README.md") }
 
     it 'should remove file with commit' do
       # Commit message valid
       expect(commit.message).to eq('Remove readme')
 
       # File was removed
-      expect(blob).to be_falsey
+      expect(blob).to be_nil
     end
   end
 
-- 
GitLab


From acdd03047a01f15ba96ec43727050e371ebb37f2 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 16:58:31 +0100
Subject: [PATCH 23/46] fixes missing comma

---
 Gemfile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Gemfile b/Gemfile
index 5a896d3..394be07 100644
--- a/Gemfile
+++ b/Gemfile
@@ -4,7 +4,7 @@ gemspec
 
 group :development do
   gem 'rubocop'
-  gem 'rubocop-rspec' '~> 1.5.0'
+  gem 'rubocop-rspec', '~> 1.5.0'
   gem 'coveralls', require: false
   gem 'rspec', '~> 3.0'
   gem 'rspec-mocks'
-- 
GitLab


From c491ddf5c6d24405f657bd35bd28bef35414571e Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 12:19:58 +0100
Subject: [PATCH 24/46] adds rename action to blob.rb

---
 lib/gitlab_git/.blob.rb.swp | Bin 0 -> 24576 bytes
 lib/gitlab_git/blob.rb      |  35 +++++++++++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)
 create mode 100644 lib/gitlab_git/.blob.rb.swp

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..b08749de7612c6e07c1f48b64a9f5c8238e677ec
GIT binary patch
literal 24576
zcmeI44U8ODeZZ%Q^Wij3(gcM-34Oi;?_P7By$jCQ66fqBHZj=2IU7<qpEq;6v$qrP
z&TMC9eZJTxIH9c+LWKedHzZVPN=4ezs6a&<sima|f*Q3|T2xvE3REo#tq2mPh<>R3
z{ok9}nb|uNyJ=CC%t*i6`FNlI_n-IP|Nq|H!qnS$>{8d*n=FotEbE%>cisLMGmoEf
zbh~B6p0gPE3qkC5JAphu$+7Fk-5Xo(#=R1J<CS*T@mCM{u0n#fC~Vf=<i%ZQp|+@h
z8vN9{Ug2_~8!Xu2!s-c@cS{MB5;!#p4C402Yu8zCxN>?*B8-o%SC?G;wo{8+hAJgc
zN}!ZLDS=V~r36X|loBW<P)gt>A%VER#=4uDoRQS#uH^S8Mt;vqt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Z@G9j
z<kRSUGUkqa@~|S9xZZN98TVQ~SmJuig-KirsUyW)&fDyKnc<sES?}kQOw)lR&#eCj
D6{d&6

literal 0
HcmV?d00001

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 94c0307..cb220c0 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -150,6 +150,14 @@ module Gitlab
           if action == :remove
             index.remove(filename)
           else
+            if action == :rename
+              old_path_name = PathHelper.normalize_path(file[:previous_path])
+              raise Repository::InvalidBlobName.new("Invalid path") if path_name.each_filename.to_a.include?('..')
+
+              old_filename = old_path_name.to_s
+              index.remove(old_filename)
+            end
+
             mode = 0o100644
             file_entry = index.get(filename)
 
@@ -207,6 +215,33 @@ module Gitlab
         def remove(repository, options)
           commit(repository, options, :remove)
         end
+
+
+        # Rename file from repository and return commit sha
+        #
+        # options should contain next structure:
+        #   file: {
+        #     previous_path: 'documents/old_story.txt'
+        #     path: 'documents/story.txt'
+        #   },
+        #   author: {
+        #     email: 'user@example.com',
+        #     name: 'Test User',
+        #     time: Time.now
+        #   },
+        #   committer: {
+        #     email: 'user@example.com',
+        #     name: 'Test User',
+        #     time: Time.now
+        #   },
+        #   commit: {
+        #     message: 'Rename FILENAME',
+        #     branch: 'master'
+        #   }
+        #
+        def rename(repository, options)
+          commit(repository, options, :rename)
+        end
       end
 
       def initialize(options)
-- 
GitLab


From 6c3f789f4fdcb2e1808f7d69f2dc88aa233642dc Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 12:44:04 +0100
Subject: [PATCH 25/46] fixes accuracy of comments on rename method

---
 lib/gitlab_git/.blob.rb.swp | Bin 24576 -> 24576 bytes
 lib/gitlab_git/blob.rb      |   2 ++
 2 files changed, 2 insertions(+)

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
index b08749de7612c6e07c1f48b64a9f5c8238e677ec..02ca93df3597f403f8fc2553d007f24b33b081d1 100644
GIT binary patch
delta 283
zcmXBPF-t;W6vpxM)=d$KZU`c@NO=h^qJc`#V1aN$qM*g1F|MnM;-Z6o0wG>-Y6x<2
zix*nEOD)>sQbW5CNRwMZ|LDLE4m|L1PCronK*g{3D&^DUekL!BE%JWSxrllX@dH~m
z%(-o{>t6(umH)J1HjkpJHwcTg;NuJqEX+d`;0Z&tafvc=h~RTg<O4H|(M26q`0x<I
z%o2IQGe)T45Cuz$l4sdL7(c5b-&o)cub85XD-^Kg{we<cxYKIexe4yIU2@Gv>Cw{Z
R)Ru0hcJ*z=HH+g|;uq4_G>ZTL

delta 262
zcmXBOze@sf9LDj_x4RSz@p}YEV8e}pa4H6eI;2AW3I`Y4Tf*g5wI!h~Xt6bJYS8ig
zPEO~4&>Dfe4f!|ph8}pq1JClzw`#ss?tN+08+d_#B}9t^?Z>;%>)5Sn6`G+o#cW-P
z<gEWSG*07GJuTBB3yjf40T;0Fof6sL9j};R03RM)9F9d27_6|w3;J+zf(-Vy$QsX>
vVTuP^DsoF{qJc8<aG;U!HNp&4XymLoZYlFK{5mopH#_wfjV{e^=j{9sem5$1

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index cb220c0..390bfb6 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -223,6 +223,8 @@ module Gitlab
         #   file: {
         #     previous_path: 'documents/old_story.txt'
         #     path: 'documents/story.txt'
+        #     content: 'Lorem ipsum...',
+        #     update: true
         #   },
         #   author: {
         #     email: 'user@example.com',
-- 
GitLab


From e7b994a7371baa47784516ded733e537d7b5a8ba Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 14:36:22 +0100
Subject: [PATCH 26/46] fixes bug regarding old_path_name in blob.rb's commit
 method

---
 lib/gitlab_git/blob.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 390bfb6..c6a902c 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -152,7 +152,7 @@ module Gitlab
           else
             if action == :rename
               old_path_name = PathHelper.normalize_path(file[:previous_path])
-              raise Repository::InvalidBlobName.new("Invalid path") if path_name.each_filename.to_a.include?('..')
+              raise Repository::InvalidBlobName.new("Invalid path") if old_path_name.each_filename.to_a.include?('..')
 
               old_filename = old_path_name.to_s
               index.remove(old_filename)
-- 
GitLab


From a8cf154a5e34f8bd89923f54761ed82830a59008 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 10:38:09 +0100
Subject: [PATCH 27/46] removes .swp file

---
 lib/gitlab_git/.blob.rb.swp | Bin 24576 -> 0 bytes
 lib/gitlab_git/blob.rb      |   2 --
 2 files changed, 2 deletions(-)
 delete mode 100644 lib/gitlab_git/.blob.rb.swp

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
deleted file mode 100644
index 02ca93df3597f403f8fc2553d007f24b33b081d1..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 24576
zcmeI44U8ODeZZ%Q^I?cXl^_VHq0e{3yI0P$=fn=lHqO~eY+`VNb2bEWK5yoBXKyFo
zo!QRJ`h2lXa6(%NQiQ^n8%WzUPzhQZ6{x5p^^4LFgj-c<5vc?esM>t=!$>$qw4nC)
ze{W`IX73!^O<PrAM*7{($D8-@fB$*&{{R1*o1c37j$70l?Tr@OPg~YgZ@K&Smv4Xc
zoFm&UEB2g)z@HCdx7!Ki`YE<sZrHWH<*wf&$=6?LcO8G_gzqY3Sc}4D?M+_Xb>?de
z`lrE9t?LyI=exnY9nP<uVR^QcKq-MUlfWQuufJxEb=8#{rsRh4v9;>bOWt;7_m-(j
z36v5jB~VJBlt3wgQUav}N(qz_cu7bg?ys`$p(W=et+_k-{i%`P^OECr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-D(VeXA@6M&_5ksp+?o}06Axc5`<$}o`_Pn<ddZBY6tClO
zDSQ%V6epLnxtT<Xw_H3M@@aHF8*@fJd03WATyMGDjC(DgEOEW%(j+d0)RAHi=WJHK
TO!G~q#QXUq(+nWVHS50s-n_1q

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index c6a902c..52d1138 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -152,8 +152,6 @@ module Gitlab
           else
             if action == :rename
               old_path_name = PathHelper.normalize_path(file[:previous_path])
-              raise Repository::InvalidBlobName.new("Invalid path") if old_path_name.each_filename.to_a.include?('..')
-
               old_filename = old_path_name.to_s
               index.remove(old_filename)
             end
-- 
GitLab


From 3b846c2d2e18a8c218088df29c3b4fde52b1fb5f Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 11:23:23 +0100
Subject: [PATCH 28/46] adds tests for renaming a file

---
 spec/.blob_snippet_spec.rb.swp | Bin 0 -> 12288 bytes
 spec/.blob_spec.rb.swp         | Bin 0 -> 28672 bytes
 spec/.spec_helper.rb.swp       | Bin 0 -> 12288 bytes
 spec/blob_spec.rb              |  48 +++++++++++++++++++++++++++++++++
 4 files changed, 48 insertions(+)
 create mode 100644 spec/.blob_snippet_spec.rb.swp
 create mode 100644 spec/.blob_spec.rb.swp
 create mode 100644 spec/.spec_helper.rb.swp

diff --git a/spec/.blob_snippet_spec.rb.swp b/spec/.blob_snippet_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..ddfee16af275096b2c18d97b3a746bd6d8f4ad99
GIT binary patch
literal 12288
zcmeI2&uY|A6vl50ZiK4X7dVZJ%)m_28HLv1Y8DlRf?%r)m5@J&nLy^=G`VG}qV0?L
z4B|WZ0Iqc9Bj^(-cy1@--xdq5D&K`KC%HNI%elX-LQcB=;LbK}1UHn7D@t7)J$txy
z^Y!xEHKlBkjEzo><#J-&{Zq#F=w3hP{*FuU4}&t%CnvuA#V~B@EWBOVGD*Ynafl^^
zO~qN5mL`oGT~rm@*v$lWda@^GK>!5KN?=7@9}d=C_BC&fR<G`!bs_RV00ck)1V8`;
zKmY_l00jO60=8OGhq905b}y@KT>34xmk1yL0w4eaAOHd&00JNY0w4eaAOHgAkU)|v
z^=?I}%}Y|e{QqBk|9`%$)F;sg(R<Mw(JRrBXeb(pE{ML$x-X)Sq9f6v=&ooax+QYH
z8zKx4009sH0T2KI5C8!X009sHf%8d#b*_l!#~+cXu=JexKw7qKr)}U4^28?Hz#8Jc
zjyE&2$9lS-O}s9>P~zc6$+i=<>0L3Hw}nTM#3&j`Gx+^^FL<DN*72uFW4ZQw^vD-C
ziN5pmpY&)T=Q1VT;=Xft)|t_k4=njr%?)cyWudw8DL3<nFShWP(o>FgQT}tq;?bkU
z;g1q|TG^*R6-bnGlhsAa6gh~l=<hS9F*@E^&3pSr&E&b}`FO%*#kD70zw*X1lNWj%
L(eBPxe^Y$}9_PtW

literal 0
HcmV?d00001

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..55948ef86f930d92ca44f0f38400a5a9ba0df0cd
GIT binary patch
literal 28672
zcmeI44~!gFea9y$32jOeFltKDQa$fU-7`M#?f-vCNY3^F4nEsGpD}T;wzD&D@5bJp
zS!QN^w{aXp0wJV?icmx)TH3@hL=cjo6a|w4{SyePigPKDsDXltBM=b@g3utOM(y|a
z=I{Q!J^LIIG%I~>_h#O_dGGgr@6Ye|elykNJGRZRLLw{S^IAzda@*m(w~s$??j!3Z
z$=2j~L$4Y(uP+#Me!ypD^R7)Q-!w<bH>DGGS?{0l#*PdpEmN6%t7g~b>g2rms^DwV
zYI0?=S~sc{`js%N{qu^BMiPi5unGyZ?AoT{g;FM+O43zhvGwfr>-MZ7gD7bvfk*<8
z1R@DU5{M)aNg$FyB!Nf*uXG96&GV$AsKmK$MY#KYPS^MO?*E=?U+X&mD);}o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$$Nlfkbj%
zv57iwB#BGJpO?$n816zLvm-9{v<BK6J%i;6uaD_7e05HNt7`A;kjC!w*y^z4;b||X
zSw^v#E769n7#iH>3R!XeVrfK3e`wMQy-{X6Vq&(0-YF9E9t552z7^?2r)?-qoo%~!
zZlWULr7PG(cAF!tbZ4O<5G66{z?jJn>v!}pubAjGU8%QJJ{~*u-jANT=|iX9d;h7M
zZ#i|-iBmV<I_ypzZR20DcCFLDWqNNkpl!A+XgVS>MsJ#KjbA~~D|V?dHrqmkCtl05
zs44V9C>?)E==63Tp=o#(j9kMeuN!BE2nB}MJh^JU2CCDsE)9jm_he0_N?;AfEhkXI
zTmQtCk1v1a@%MmRm%q4tf<6Ae<p-8eEI&N5T9_@oXGQj(^mnUv`aQP4PITR6fI_&b
z0)+^Vr(VzZI<dF#^uEKL8o!4>h#$QD$gS|oFAVY%hO_QfF&qhpeTEY|ZP@WTs~+#y
zfVY?hYnO0_eTM2Y%P_2tArbjir(^vhzIxsXX13<%@$LiRx%00M9YiLxB8l_vwnWV|
d8Wra~a3N<=!ntCCIcE|F@Ce&DUh=d-`hQwNYCQk|

literal 0
HcmV?d00001

diff --git a/spec/.spec_helper.rb.swp b/spec/.spec_helper.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..1246342965bda0d19fc0e816501ebebf323977e9
GIT binary patch
literal 12288
zcmeI2PmkL~6u_rFfK(_TK%xf@v&+F7(Kzi=6%lC<*^=$9lx(8>Sq^9!jqR6Ys<Fq6
z$0>p3&xtDs1QL7(1SdWK2*GDS9QXoAd;mD`Y=`{=+a*14sPruTGP2*B@tfb+k)lj+
z<6y7LU-fS>Jf30f%J#c&^j`bs@(*i_IVGni35)|hGe!IXM|ZnlkDxv(((9YPmdW{v
zADkJmk=d|uS2-<%#<Xk%HjONWu>24+&?#8o2Ir4PSIGbwcsK)B*(;kjZxnrAT3_SO
zJv)B5?vzai$N(8217v^<kO4A42FSo8ZNR0M*oQcS%gb53ylgN1qg|d-Lk7qI86X2>
zfDDiUGC&5%02v?yWPl7jf(B&7*u5)^Z9aj;<NyDE|Nj5|X~up=enP%SzCyl4K1V)7
zK0++=7IKK(MxIB0dy28|kS`F6bPx}D9C-}+<tmPee2aX72xJ|35xIuEfc*F*V;>_e
z<WH>Y59C+mYvfa8fgB>Yk)rOK2pwdA43GgbKnBPF86X2>;QuiINyIo0O)^naKY)p`
zu+fxS*Z6xJk}S6%GJq)K@1LZpB-D8Xe29VFa$D<3%-9Gl-{PK?Nn~R0Br;LjffY7S
zcynUHJUa>DHG%gO_h*m@n1fxonM$Uj>H-mt=WGsaFvRV&epM`1#v{Xzs<R`;M(yE9
zbjPFCcBd@{?S4=6Tccg<x}!As_l!z5hU0#}HyD+H>wG=VoeVV8Eu_ZB-MZ_wYLNZj
zpxf%KHb!DxJ&^X_gRD}4SM3z8V^epKxuOWK#!i=crv7p!@J@<qMJnBFqr4C)o5&b8
zgxJ}`sf$|eI`@3Pk>zP>Y%w6KR=N7*T!t=}+LyVT87qpud~2&*%>kNdHt(1?R<7A>
zjYqq^f!G;$I%2=oZR3I+ca9;;<n#d@yY1nyb@xoZ!bLpq9(%8!8kMhY@kD975=$4(
z%Jr>^J*w8e+3Xepu$dphL?ytR0f@QODiUE?HTJ=uYVdZh@X58HrBid@-qJ;*SZeR0
zcpfZ7piOX5QlO^GyIqu}W#(2$n<%?d9wecOikG6A=S6phICYB^^8S0I;?-a7T=$N(
z;=5gLYgaBiu7Z21U7R|r9_(TZJoc-eyP=9x4R_4k&z!Ul7kRl%xH@GhG;@!E&HzK0
k1{S{(GXFkEyLLJm)2fii)P%S958m`fgVw>`&^u&*0gcb<CIA2c

literal 0
HcmV?d00001

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 6998ea3..969d058 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -270,6 +270,54 @@ describe Gitlab::Git::Blob do
     end
   end
 
+  describe :rename do
+    let(:repository) { Gitlab::Git::Repository.new(TEST_NORMAL_REPO_PATH) }
+
+    let(:commit_options) do
+      options = {
+        file: {
+          path: 'NEWREADME.md',
+          previous_path: 'README.md',
+          content: 'Lorem ipsum...',
+          update: true
+        },
+        author: {
+          email: 'user@example.com',
+          name: 'Test User',
+          time: Time.now
+        },
+        committer: {
+          email: 'user@example.com',
+          name: 'Test User',
+          time: Time.now
+        },
+        commit: {
+          message: 'Rename readme',
+          branch: 'master'
+        }
+      }
+    end
+
+    let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
+    let!(:commit) { repository.lookup(commit_sha) }
+
+    it 'should rename the file with commit' do
+      # Commit message valid
+      expect(commit.message).to eq('Rename readme')
+
+      # Previous file was removed
+      expect(commit.tree.to_a.any? do |tree|
+        tree[:name] == 'README.md'
+      end).to be_falsey
+
+      # File was renamed
+      expect(commit.tree.to_a.any? do |tree|
+        tree[:name] == 'NEWREADME.md'
+      end).to be_truthy
+
+    end
+  end
+
   describe :remove do
     let(:repository) { Gitlab::Git::Repository.new(TEST_REPO_PATH) }
 
-- 
GitLab


From 842bdbcfb2b71cc86ed5453a6dd91f31ab6cc74b Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 12:11:28 +0100
Subject: [PATCH 29/46] removes swp files

---
 spec/.blob_snippet_spec.rb.swp | Bin 12288 -> 0 bytes
 spec/.blob_spec.rb.swp         | Bin 28672 -> 0 bytes
 spec/.spec_helper.rb.swp       | Bin 12288 -> 0 bytes
 3 files changed, 0 insertions(+), 0 deletions(-)
 delete mode 100644 spec/.blob_snippet_spec.rb.swp
 delete mode 100644 spec/.blob_spec.rb.swp
 delete mode 100644 spec/.spec_helper.rb.swp

diff --git a/spec/.blob_snippet_spec.rb.swp b/spec/.blob_snippet_spec.rb.swp
deleted file mode 100644
index ddfee16af275096b2c18d97b3a746bd6d8f4ad99..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 12288
zcmeI2&uY|A6vl50ZiK4X7dVZJ%)m_28HLv1Y8DlRf?%r)m5@J&nLy^=G`VG}qV0?L
z4B|WZ0Iqc9Bj^(-cy1@--xdq5D&K`KC%HNI%elX-LQcB=;LbK}1UHn7D@t7)J$txy
z^Y!xEHKlBkjEzo><#J-&{Zq#F=w3hP{*FuU4}&t%CnvuA#V~B@EWBOVGD*Ynafl^^
zO~qN5mL`oGT~rm@*v$lWda@^GK>!5KN?=7@9}d=C_BC&fR<G`!bs_RV00ck)1V8`;
zKmY_l00jO60=8OGhq905b}y@KT>34xmk1yL0w4eaAOHd&00JNY0w4eaAOHgAkU)|v
z^=?I}%}Y|e{QqBk|9`%$)F;sg(R<Mw(JRrBXeb(pE{ML$x-X)Sq9f6v=&ooax+QYH
z8zKx4009sH0T2KI5C8!X009sHf%8d#b*_l!#~+cXu=JexKw7qKr)}U4^28?Hz#8Jc
zjyE&2$9lS-O}s9>P~zc6$+i=<>0L3Hw}nTM#3&j`Gx+^^FL<DN*72uFW4ZQw^vD-C
ziN5pmpY&)T=Q1VT;=Xft)|t_k4=njr%?)cyWudw8DL3<nFShWP(o>FgQT}tq;?bkU
z;g1q|TG^*R6-bnGlhsAa6gh~l=<hS9F*@E^&3pSr&E&b}`FO%*#kD70zw*X1lNWj%
L(eBPxe^Y$}9_PtW

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
deleted file mode 100644
index 55948ef86f930d92ca44f0f38400a5a9ba0df0cd..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 28672
zcmeI44~!gFea9y$32jOeFltKDQa$fU-7`M#?f-vCNY3^F4nEsGpD}T;wzD&D@5bJp
zS!QN^w{aXp0wJV?icmx)TH3@hL=cjo6a|w4{SyePigPKDsDXltBM=b@g3utOM(y|a
z=I{Q!J^LIIG%I~>_h#O_dGGgr@6Ye|elykNJGRZRLLw{S^IAzda@*m(w~s$??j!3Z
z$=2j~L$4Y(uP+#Me!ypD^R7)Q-!w<bH>DGGS?{0l#*PdpEmN6%t7g~b>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>aBY)iw-E(A
z-_lf0TkGDo?n*5-=-Sn^U%xzF-mPi!`4--AaT?7jHUmfPa)=g57FXHry0-B~ZAa|*
z`MVIoNJ5>-+W?~9L$?Z@1TT-CciP=;RgbvS06Ij#eL9?YMikn^m+*|}=$$Nlfkbj%
zv57iwB#BGJpO?$n816zLvm-9{v<BK6J%i;6uaD_7e05HNt7`A;kjC!w*y^z4;b||X
zSw^v#E769n7#iH>3R!XeVrfK3e`wMQy-{X6Vq&(0-YF9E9t552z7^?2r)?-qoo%~!
zZlWULr7PG(cAF!tbZ4O<5G66{z?jJn>v!}pubAjGU8%QJJ{~*u-jANT=|iX9d;h7M
zZ#i|-iBmV<I_ypzZR20DcCFLDWqNNkpl!A+XgVS>MsJ#KjbA~~D|V?dHrqmkCtl05
zs44V9C>?)E==63Tp=o#(j9kMeuN!BE2nB}MJh^JU2CCDsE)9jm_he0_N?;AfEhkXI
zTmQtCk1v1a@%MmRm%q4tf<6Ae<p-8eEI&N5T9_@oXGQj(^mnUv`aQP4PITR6fI_&b
z0)+^Vr(VzZI<dF#^uEKL8o!4>h#$QD$gS|oFAVY%hO_QfF&qhpeTEY|ZP@WTs~+#y
zfVY?hYnO0_eTM2Y%P_2tArbjir(^vhzIxsXX13<%@$LiRx%00M9YiLxB8l_vwnWV|
d8Wra~a3N<=!ntCCIcE|F@Ce&DUh=d-`hQwNYCQk|

diff --git a/spec/.spec_helper.rb.swp b/spec/.spec_helper.rb.swp
deleted file mode 100644
index 1246342965bda0d19fc0e816501ebebf323977e9..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 12288
zcmeI2PmkL~6u_rFfK(_TK%xf@v&+F7(Kzi=6%lC<*^=$9lx(8>Sq^9!jqR6Ys<Fq6
z$0>p3&xtDs1QL7(1SdWK2*GDS9QXoAd;mD`Y=`{=+a*14sPruTGP2*B@tfb+k)lj+
z<6y7LU-fS>Jf30f%J#c&^j`bs@(*i_IVGni35)|hGe!IXM|ZnlkDxv(((9Y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00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 12:12:18 +0100
Subject: [PATCH 30/46] removes redundant empty line

---
 spec/.blob_spec.rb.swp | Bin 0 -> 24576 bytes
 spec/blob_spec.rb      |   1 -
 2 files changed, 1 deletion(-)
 create mode 100644 spec/.blob_spec.rb.swp

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..18e1c7e9ced827d737cf8ae4a2790989f9456be1
GIT binary patch
literal 24576
zcmeI34Uingb;rjTa2$iNaoI6APPJB5*^{~3o7wMOn}U<>h~?Z#^66wDVP(@h(|bE;
zcV?NHy}LzUu@MfTATHy?NyYiH0h?fqOeHQ`F$qa*hon*kA|_B#oT411utOPAMm8y`
z;!6JA^SxhpCkX+`Zq-kF+Uf4;dHwqJd#`({@<+DLkwPjf;qx|0I&}Mi-FJ?C<$_;O
zB+1d~qG?o3hc)UZzdqnIw|U2e#wHec@riV*L5=<e562puv@Lb=mvpB=tCNf3tAejd
zyT#PWYQwBn_+Kfj+P|&QuOkVJB(M$%w4K^S@lq+1R%BjlV`2k&$K|`$(ZHzaNCG1X
zj3h9Uz(@ik35+B#lE6p;BMH3TCE&C!l#bvbF7O_NdEam7`o75fzaQGyx~^a7{r^_)
z`^m2BZ}k5EE8h2B?*{&Tyq`y3BMFQoFp|JX0wW2GBruY|NCG1Xj3h9Uz(@ik35+E0
z3P^xzlJrir`)wYGWB=ce|6jOFlAZ@ogQvjPK^r(=FW3kY;3DwMTP5jXa2L2890j)k
z6Kn_1T`Ecc0UiV<$bi$ANYdS)13m;cgDJ2PJo*+%`dhFJror366F)0SzYX?-4}dJl
zfD6FAZ<eHcz%Gyg|M@eLbPU*FE4UI|4&Dxa^d__eehaif9V~(mg3}jE(u?43a5LzD
z&EQJ#5)vRk1pf|Bfk(mhpaAmVV(>VUAdi8&!EP`IX2CeP5d0&OAb$t`3j8@Z4!!_(
zfp>$GNWwe_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
a4?L1yO1U-0iF+k=BaZEk;U&*a(*FWE^rH&^

literal 0
HcmV?d00001

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 969d058..0d89582 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -314,7 +314,6 @@ describe Gitlab::Git::Blob do
       expect(commit.tree.to_a.any? do |tree|
         tree[:name] == 'NEWREADME.md'
       end).to be_truthy
-
     end
   end
 
-- 
GitLab


From 01088c8747a9b05567e11afcf14b5414d055463f Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 12:19:58 +0100
Subject: [PATCH 31/46] adds rename action to blob.rb

---
 lib/gitlab_git/.blob.rb.swp | Bin 0 -> 24576 bytes
 lib/gitlab_git/blob.rb      |   3 +++
 2 files changed, 3 insertions(+)
 create mode 100644 lib/gitlab_git/.blob.rb.swp

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..b08749de7612c6e07c1f48b64a9f5c8238e677ec
GIT binary patch
literal 24576
zcmeI44U8ODeZZ%Q^Wij3(gcM-34Oi;?_P7By$jCQ66fqBHZj=2IU7<qpEq;6v$qrP
z&TMC9eZJTxIH9c+LWKedHzZVPN=4ezs6a&<sima|f*Q3|T2xvE3REo#tq2mPh<>R3
z{ok9}nb|uNyJ=CC%t*i6`FNlI_n-IP|Nq|H!qnS$>{8d*n=FotEbE%>cisLMGmoEf
zbh~B6p0gPE3qkC5JAphu$+7Fk-5Xo(#=R1J<CS*T@mCM{u0n#fC~Vf=<i%ZQp|+@h
z8vN9{Ug2_~8!Xu2!s-c@cS{MB5;!#p4C402Yu8zCxN>?*B8-o%SC?G;wo{8+hAJgc
zN}!ZLDS=V~r36X|loBW<P)gt>A%VER#=4uDoRQS#uH^S8Mt;vqt~VsVhew{TNv>1V
z|05&M&rGhh@xl4Oj66>+%b!vLr36X|loBW<P)eYbKq-Mz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kQOw)lR&#eCj
D6{d&6

literal 0
HcmV?d00001

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 52d1138..644f8cd 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -221,8 +221,11 @@ module Gitlab
         #   file: {
         #     previous_path: 'documents/old_story.txt'
         #     path: 'documents/story.txt'
+<<<<<<< 7022a6d0d019114abec393f434256548a01a529e
         #     content: 'Lorem ipsum...',
         #     update: true
+=======
+>>>>>>> adds rename action to blob.rb
         #   },
         #   author: {
         #     email: 'user@example.com',
-- 
GitLab


From 29745d85e955d9fe42dbe0d91c2f0af3c8d5e22f Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 12:44:04 +0100
Subject: [PATCH 32/46] fixes accuracy of comments on rename method

---
 lib/gitlab_git/.blob.rb.swp | Bin 24576 -> 24576 bytes
 lib/gitlab_git/blob.rb      |   3 ---
 2 files changed, 3 deletions(-)

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
index b08749de7612c6e07c1f48b64a9f5c8238e677ec..02ca93df3597f403f8fc2553d007f24b33b081d1 100644
GIT binary patch
delta 283
zcmXBPF-t;W6vpxM)=d$KZU`c@NO=h^qJc`#V1aN$qM*g1F|MnM;-Z6o0wG>-Y6x<2
zix*nEOD)>sQbW5CNRwMZ|LDLE4m|L1PCronK*g{3D&^DUekL!BE%JWSxrllX@dH~m
z%(-o{>t6(umH)J1HjkpJHwcTg;NuJqEX+d`;0Z&tafvc=h~RTg<O4H|(M26q`0x<I
z%o2IQGe)T45Cuz$l4sdL7(c5b-&o)cub85XD-^Kg{we<cxYKIexe4yIU2@Gv>Cw{Z
R)Ru0hcJ*z=HH+g|;uq4_G>ZTL

delta 262
zcmXBOze@sf9LDj_x4RSz@p}YEV8e}pa4H6eI;2AW3I`Y4Tf*g5wI!h~Xt6bJYS8ig
zPEO~4&>Dfe4f!|ph8}pq1JClzw`#ss?tN+08+d_#B}9t^?Z>;%>)5Sn6`G+o#cW-P
z<gEWSG*07GJuTBB3yjf40T;0Fof6sL9j};R03RM)9F9d27_6|w3;J+zf(-Vy$QsX>
vVTuP^DsoF{qJc8<aG;U!HNp&4XymLoZYlFK{5mopH#_wfjV{e^=j{9sem5$1

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 644f8cd..52d1138 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -221,11 +221,8 @@ module Gitlab
         #   file: {
         #     previous_path: 'documents/old_story.txt'
         #     path: 'documents/story.txt'
-<<<<<<< 7022a6d0d019114abec393f434256548a01a529e
         #     content: 'Lorem ipsum...',
         #     update: true
-=======
->>>>>>> adds rename action to blob.rb
         #   },
         #   author: {
         #     email: 'user@example.com',
-- 
GitLab


From ed2627568ca7a3ce36285f069eb9d8591da7cd5c Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Mon, 4 Jul 2016 14:36:22 +0100
Subject: [PATCH 33/46] fixes bug regarding old_path_name in blob.rb's commit
 method

---
 lib/gitlab_git/blob.rb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index 52d1138..aa2fe6f 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -152,6 +152,7 @@ module Gitlab
           else
             if action == :rename
               old_path_name = PathHelper.normalize_path(file[:previous_path])
+
               old_filename = old_path_name.to_s
               index.remove(old_filename)
             end
-- 
GitLab


From 4330c3e79d9c37ba507d121195f7b3fe4b3300c4 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 10:38:09 +0100
Subject: [PATCH 34/46] removes .swp file

---
 lib/gitlab_git/.blob.rb.swp | Bin 24576 -> 0 bytes
 lib/gitlab_git/blob.rb      |   1 -
 2 files changed, 1 deletion(-)
 delete mode 100644 lib/gitlab_git/.blob.rb.swp

diff --git a/lib/gitlab_git/.blob.rb.swp b/lib/gitlab_git/.blob.rb.swp
deleted file mode 100644
index 02ca93df3597f403f8fc2553d007f24b33b081d1..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 24576
zcmeI44U8ODeZZ%Q^I?cXl^_VHq0e{3yI0P$=fn=lHqO~eY+`VNb2bEWK5yoBXKyFo
zo!QRJ`h2lXa6(%NQiQ^n8%WzUPzhQZ6{x5p^^4LFgj-c<5vc?esM>t=!$>$qw4nC)
ze{W`IX73!^O<PrAM*7{($D8-@fB$*&{{R1*o1c37j$70l?Tr@OPg~YgZ@K&Smv4Xc
zoFm&UEB2g)z@HCdx7!Ki`YE<sZrHWH<*wf&$=6?LcO8G_gzqY3Sc}4D?M+_Xb>?de
z`lrE9t?LyI=exnY9nP<uVR^QcKq-MUlfWQuufJxEb=8#{rsRh4v9;>bOWt;7_m-(j
z36v5jB~VJBlt3wgQUav}N(qz_cu7bg?ys`$p(W=et+_k-{i%`P^OECr$?u_&>#LIE
ze)9XVk?ZFs$J+Q{|DQ*$Cx_)vDS=V~r36X|loBW<P)eYbKq-Mz0;L2>36v5jCGfu>
z0jFhIW8}L|900`sQ~Up$udu8?f<J^u;Wy!f(1+bH1LwgPFSe`*w!_cD>)<PEEb9sQ
zJlqfSumz^!<VBYCeK-zZg@+-4J7EH<@Jjg6%Ps3$@cZx~cqhCbE`(=Z#ySOf0v?0k
zh0nnK(1Iqs6*j?T@SW9`^)>hkJOK~F2jE_qg^jQV{_#S~`UX4+?}MZ8CU_N`ynr&{
zbMRUCCD;eM;H|J8CSeWy?fJ+KLTJKTxD+mc^WkrBru+%~8Z1E*-U2lkhgZX^;2Stq
zo`i?tSD*#g!t3A_@I#y`e+7@i18^VQ1zSPExp0zx{T6&4J`BGMM_@ZhpI-r|-_&qx
zdtFy;RzW}Z0zaCq%ki9*UT(Q<)eL$)FRq4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Wr0BzU>
z>)-<TA@=(T_%a-W`{7<V3QZ6j{{;5?-@|v|PvL#A7iQo#*aEMI*TQSyWgu(&pMz)N
z7%ajJTmsMX4;-FJ|A~Y2sr0>UrEzR&Iq;`6j$Z=CaXHO@34d`?PV<L@RXT?+r}^bH
z|0iRbpHuyn%rP_3<qI<L>4^7g<@qkpP3{^KWI5EUWMyuwUBKDo$jl7RaAu!O_qC_k
zn1ETf;vODWND6VXZ>1`H>sGW(O&y1KQ^{Q{<2B2H`3f=YX@|1;K1y0STQB(Wat>^1
z0G2}foh2VOVb{>koGh2E!!HPOB_WPxC=$=hY}7PMhA5gb%Nq5#VO$CMubfgtUMwQx
z4ag<b%jSy$%3USbP`gjW7h<y@0aGW}IwrWMvdd;jFCV0gr5$HJEY<G*%=F4KFXlQd
zQz{@n1d7M3_E~B_%Wl4Pi4mt$6+<TUjxo^EOtkEC1*PKW`cNH~>F6n2ShPITW=cjc
zMnA{Z*7+bLB7<J}OVnRmxvGf^06k+B2=d^wS6@|Kn<e|UU26wHzW;_Tp;f0<Y$}UB
z=R`89T?m_eD*QyX4*C<-D(VeXA@6M&_5ksp+?o}06Axc5`<$}o`_Pn<ddZBY6tClO
zDSQ%V6epLnxtT<Xw_H3M@@aHF8*@fJd03WATyMGDjC(DgEOEW%(j+d0)RAHi=WJHK
TO!G~q#QXUq(+nWVHS50s-n_1q

diff --git a/lib/gitlab_git/blob.rb b/lib/gitlab_git/blob.rb
index aa2fe6f..52d1138 100644
--- a/lib/gitlab_git/blob.rb
+++ b/lib/gitlab_git/blob.rb
@@ -152,7 +152,6 @@ module Gitlab
           else
             if action == :rename
               old_path_name = PathHelper.normalize_path(file[:previous_path])
-
               old_filename = old_path_name.to_s
               index.remove(old_filename)
             end
-- 
GitLab


From b9f569c919d3d25527b8a28cb48927b72f3266b0 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 11:23:23 +0100
Subject: [PATCH 35/46] adds tests for renaming a file

---
 spec/.blob_snippet_spec.rb.swp | Bin 0 -> 12288 bytes
 spec/.spec_helper.rb.swp       | Bin 0 -> 12288 bytes
 2 files changed, 0 insertions(+), 0 deletions(-)
 create mode 100644 spec/.blob_snippet_spec.rb.swp
 create mode 100644 spec/.spec_helper.rb.swp

diff --git a/spec/.blob_snippet_spec.rb.swp b/spec/.blob_snippet_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..ddfee16af275096b2c18d97b3a746bd6d8f4ad99
GIT binary patch
literal 12288
zcmeI2&uY|A6vl50ZiK4X7dVZJ%)m_28HLv1Y8DlRf?%r)m5@J&nLy^=G`VG}qV0?L
z4B|WZ0Iqc9Bj^(-cy1@--xdq5D&K`KC%HNI%elX-LQcB=;LbK}1UHn7D@t7)J$txy
z^Y!xEHKlBkjEzo><#J-&{Zq#F=w3hP{*FuU4}&t%CnvuA#V~B@EWBOVGD*Ynafl^^
zO~qN5mL`oGT~rm@*v$lWda@^GK>!5KN?=7@9}d=C_BC&fR<G`!bs_RV00ck)1V8`;
zKmY_l00jO60=8OGhq905b}y@KT>34xmk1yL0w4eaAOHd&00JNY0w4eaAOHgAkU)|v
z^=?I}%}Y|e{QqBk|9`%$)F;sg(R<Mw(JRrBXeb(pE{ML$x-X)Sq9f6v=&ooax+QYH
z8zKx4009sH0T2KI5C8!X009sHf%8d#b*_l!#~+cXu=JexKw7qKr)}U4^28?Hz#8Jc
zjyE&2$9lS-O}s9>P~zc6$+i=<>0L3Hw}nTM#3&j`Gx+^^FL<DN*72uFW4ZQw^vD-C
ziN5pmpY&)T=Q1VT;=Xft)|t_k4=njr%?)cyWudw8DL3<nFShWP(o>FgQT}tq;?bkU
z;g1q|TG^*R6-bnGlhsAa6gh~l=<hS9F*@E^&3pSr&E&b}`FO%*#kD70zw*X1lNWj%
L(eBPxe^Y$}9_PtW

literal 0
HcmV?d00001

diff --git a/spec/.spec_helper.rb.swp b/spec/.spec_helper.rb.swp
new file mode 100644
index 0000000000000000000000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Bid@-qJ;*SZeR0
zcpfZ7piOX5QlO^GyIqu}W#(2$n<%?d9wecOikG6A=S6phICYB^^8S0I;?-a7T=$N(
z;=5gLYgaBiu7Z21U7R|r9_(TZJoc-eyP=9x4R_4k&z!Ul7kRl%xH@GhG;@!E&HzK0
k1{S{(GXFkEyLLJm)2fii)P%S958m`fgVw>`&^u&*0gcb<CIA2c

literal 0
HcmV?d00001

-- 
GitLab


From 849b1c114ff2b1c48441c8f7b07df5bf552f1cc6 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 12:11:28 +0100
Subject: [PATCH 36/46] removes swp files

---
 spec/.blob_snippet_spec.rb.swp | Bin 12288 -> 0 bytes
 spec/.blob_spec.rb.swp         | Bin 24576 -> 0 bytes
 spec/.spec_helper.rb.swp       | Bin 12288 -> 0 bytes
 3 files changed, 0 insertions(+), 0 deletions(-)
 delete mode 100644 spec/.blob_snippet_spec.rb.swp
 delete mode 100644 spec/.blob_spec.rb.swp
 delete mode 100644 spec/.spec_helper.rb.swp

diff --git a/spec/.blob_snippet_spec.rb.swp b/spec/.blob_snippet_spec.rb.swp
deleted file mode 100644
index ddfee16af275096b2c18d97b3a746bd6d8f4ad99..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 12288
zcmeI2&uY|A6vl50ZiK4X7dVZJ%)m_28HLv1Y8DlRf?%r)m5@J&nLy^=G`VG}qV0?L
z4B|WZ0Iqc9Bj^(-cy1@--xdq5D&K`KC%HNI%elX-LQcB=;LbK}1UHn7D@t7)J$txy
z^Y!xEHKlBkjEzo><#J-&{Zq#F=w3hP{*FuU4}&t%CnvuA#V~B@EWBOVGD*Ynafl^^
zO~qN5mL`oGT~rm@*v$lWda@^GK>!5KN?=7@9}d=C_BC&fR<G`!bs_RV00ck)1V8`;
zKmY_l00jO60=8OGhq905b}y@KT>34xmk1yL0w4eaAOHd&00JNY0w4eaAOHgAkU)|v
z^=?I}%}Y|e{QqBk|9`%$)F;sg(R<Mw(JRrBXeb(pE{ML$x-X)Sq9f6v=&ooax+QYH
z8zKx4009sH0T2KI5C8!X009sHf%8d#b*_l!#~+cXu=JexKw7qKr)}U4^28?Hz#8Jc
zjyE&2$9lS-O}s9>P~zc6$+i=<>0L3Hw}nTM#3&j`Gx+^^FL<DN*72uFW4ZQw^vD-C
ziN5pmpY&)T=Q1VT;=Xft)|t_k4=njr%?)cyWudw8DL3<nFShWP(o>FgQT}tq;?bkU
z;g1q|TG^*R6-bnGlhsAa6gh~l=<hS9F*@E^&3pSr&E&b}`FO%*#kD70zw*X1lNWj%
L(eBPxe^Y$}9_PtW

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
deleted file mode 100644
index 18e1c7e9ced827d737cf8ae4a2790989f9456be1..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 24576
zcmeI34Uingb;rjTa2$iNaoI6APPJB5*^{~3o7wMOn}U<>h~?Z#^66wDVP(@h(|bE;
zcV?NHy}LzUu@MfTATHy?NyYiH0h?fqOeHQ`F$qa*hon*kA|_B#oT411utOPAMm8y`
z;!6JA^SxhpCkX+`Zq-kF+Uf4;dHwqJd#`({@<+DLkwPjf;qx|0I&}Mi-FJ?C<$_;O
zB+1d~qG?o3hc)UZzdqnIw|U2e#wHec@riV*L5=<e562puv@Lb=mvpB=tCNf3tAejd
zyT#PWYQwBn_+Kfj+P|&QuOkVJB(M$%w4K^S@lq+1R%BjlV`2k&$K|`$(ZHzaNCG1X
zj3h9Uz(@ik35+B#lE6p;BMH3TCE&C!l#bvbF7O_NdEam7`o75fzaQGyx~^a7{r^_)
z`^m2BZ}k5EE8h2B?*{&Tyq`y3BMFQoFp|JX0wW2GBruY|NCG1Xj3h9Uz(@ik35+E0
z3P^xzlJrir`)wYGWB=ce|6jOFlAZ@ogQvjPK^r(=FW3kY;3DwMTP5jXa2L2890j)k
z6Kn_1T`Ecc0UiV<$bi$ANYdS)13m;cgDJ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;^>L5oH%~s8*5eztBv=pXmHZsd$cp3vHf+T>n;Nn!YdUj
zMAV-8GvA-YzDMSNM<+G@9)1u%eEZRR;MHFk3<^e@?o~1T65aNR7Iw!l_Bv~iTRz||
z=FoSEHrU5hpIw7db&QB8cy#_-zl?9sJHb|aaS`u6@bY2TBR`^%c~QiDcRN+H%x1-X
a4?L1yO1U-0iF+k=BaZEk;U&*a(*FWE^rH&^

diff --git a/spec/.spec_helper.rb.swp b/spec/.spec_helper.rb.swp
deleted file mode 100644
index 1246342965bda0d19fc0e816501ebebf323977e9..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 12288
zcmeI2PmkL~6u_rFfK(_TK%xf@v&+F7(Kzi=6%lC<*^=$9lx(8>Sq^9!jqR6Ys<Fq6
z$0>p3&xtDs1QL7(1SdWK2*GDS9QXoAd;mD`Y=`{=+a*14sPruTGP2*B@tfb+k)lj+
z<6y7LU-fS>Jf30f%J#c&^j`bs@(*i_IVGni35)|hGe!IXM|ZnlkDxv(((9YPmdW{v
zADkJmk=d|uS2-<%#<Xk%HjONWu>24+&?#8o2Ir4PSIGbwcsK)B*(;kjZxnrAT3_SO
zJv)B5?vzai$N(8217v^<kO4A42FSo8ZNR0M*oQcS%gb53ylgN1qg|d-Lk7qI86X2>
zfDDiUGC&5%02v?yWPl7jf(B&7*u5)^Z9aj;<NyDE|Nj5|X~up=enP%SzCyl4K1V)7
zK0++=7IKK(MxIB0dy28|kS`F6bPx}D9C-}+<tmPee2aX72xJ|35xIuEfc*F*V;>_e
z<WH>Y59C+mYvfa8fgB>Yk)rOK2pwdA43GgbKnBPF86X2>;QuiINyIo0O)^naKY)p`
zu+fxS*Z6xJk}S6%GJq)K@1LZpB-D8Xe29VFa$D<3%-9Gl-{PK?Nn~R0Br;LjffY7S
zcynUHJUa>DHG%gO_h*m@n1fxonM$Uj>H-mt=WGsaFvRV&epM`1#v{Xzs<R`;M(yE9
zbjPFCcBd@{?S4=6Tccg<x}!As_l!z5hU0#}HyD+H>wG=VoeVV8Eu_ZB-MZ_wYLNZj
zpxf%KHb!DxJ&^X_gRD}4SM3z8V^epKxuOWK#!i=crv7p!@J@<qMJnBFqr4C)o5&b8
zgxJ}`sf$|eI`@3Pk>zP>Y%w6KR=N7*T!t=}+LyVT87qpud~2&*%>kNdHt(1?R<7A>
zjYqq^f!G;$I%2=oZR3I+ca9;;<n#d@yY1nyb@xoZ!bLpq9(%8!8kMhY@kD975=$4(
z%Jr>^J*w8e+3Xepu$dphL?ytR0f@QODiUE?HTJ=uYVdZh@X58HrBid@-qJ;*SZeR0
zcpfZ7piOX5QlO^GyIqu}W#(2$n<%?d9wecOikG6A=S6phICYB^^8S0I;?-a7T=$N(
z;=5gLYgaBiu7Z21U7R|r9_(TZJoc-eyP=9x4R_4k&z!Ul7kRl%xH@GhG;@!E&HzK0
k1{S{(GXFkEyLLJm)2fii)P%S958m`fgVw>`&^u&*0gcb<CIA2c

-- 
GitLab


From 57ddb1a3c86939db130150f951aec1e893f4bdb5 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 12:12:18 +0100
Subject: [PATCH 37/46] removes redundant empty line

---
 spec/.blob_spec.rb.swp | Bin 0 -> 24576 bytes
 1 file changed, 0 insertions(+), 0 deletions(-)
 create mode 100644 spec/.blob_spec.rb.swp

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
new file mode 100644
index 0000000000000000000000000000000000000000..18e1c7e9ced827d737cf8ae4a2790989f9456be1
GIT binary patch
literal 24576
zcmeI34Uingb;rjTa2$iNaoI6APPJB5*^{~3o7wMOn}U<>h~?Z#^66wDVP(@h(|bE;
zcV?NHy}LzUu@MfTATHy?NyYiH0h?fqOeHQ`F$qa*hon*kA|_B#oT411utOPAMm8y`
z;!6JA^SxhpCkX+`Zq-kF+Uf4;dHwqJd#`({@<+DLkwPjf;qx|0I&}Mi-FJ?C<$_;O
zB+1d~qG?o3hc)UZzd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sw;;bZvPdhMC*kdeLd3~&p`HC-r>l*LukiqVAY;{=i=(3m4ZL?U+m3Y7=
zOoKOEA_L3M#P;M~H}f~=#4)DGq7`|gY!*4OEs=MM68=HZ$?jWmorrJriHzXZo!cjP
zm+;aRf=F*TqDuD)3<R<yYc-6S?67&q5A%wJPB+v>TVrF1Qy=^EsgK`r>SM=F-SUZ3
zA3uKTmfMEiDK<7ijdM3T{YR$vMgzuXOI<gRiCO#5bZh)7f?jn>Z6xz;oNvHudCR)W
zUkEkuFBdw0J5OjDUIn8yWM#z*qas5=@S3Nm*5^QVVt#4l7*J2syjLlBIm~twCBFZY
zIC1ZZzkK4?z-=eKe&RTJ;^>L5oH%~s8*5eztBv=pXmHZsd$cp3vHf+T>n;Nn!YdUj
zMAV-8GvA-YzDMSNM<+G@9)1u%eEZRR;MHFk3<^e@?o~1T65aNR7Iw!l_Bv~iTRz||
z=FoSEHrU5hpIw7db&QB8cy#_-zl?9sJHb|aaS`u6@bY2TBR`^%c~QiDcRN+H%x1-X
a4?L1yO1U-0iF+k=BaZEk;U&*a(*FWE^rH&^

literal 0
HcmV?d00001

-- 
GitLab


From ac07a9c40f216b3f9afbd9fddb65fd17a1739a00 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Tue, 5 Jul 2016 15:02:21 +0100
Subject: [PATCH 38/46] removes .swp file

---
 spec/.blob_spec.rb.swp | Bin 24576 -> 0 bytes
 1 file changed, 0 insertions(+), 0 deletions(-)
 delete mode 100644 spec/.blob_spec.rb.swp

diff --git a/spec/.blob_spec.rb.swp b/spec/.blob_spec.rb.swp
deleted file mode 100644
index 18e1c7e9ced827d737cf8ae4a2790989f9456be1..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 24576
zcmeI34Uingb;rjTa2$iNaoI6APPJB5*^{~3o7wMOn}U<>h~?Z#^66wDVP(@h(|bE;
zcV?NHy}LzUu@MfTATHy?NyYiH0h?fqOeHQ`F$qa*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@rKJ845tVN);i^|S0WeJIqkaK__dBBJpRB72`veq
zOuhri{~j7DxCLGtGw+P2+q#apa|1d=z<nm1I3o(}VJkQzy7oyHtsrqZuR28W8%d&y
z_~*4^8>3Sw;;bZvPdhMC*kdeLd3~&p`HC-r>l*LukiqVAY;{=i=(3m4ZL?U+m3Y7=
zOoKOEA_L3M#P;M~H}f~=#4)DGq7`|gY!*4OEs=MM68=HZ$?jWmorrJriHzXZo!cjP
zm+;aRf=F*TqDuD)3<R<yYc-6S?67&q5A%wJPB+v>TVrF1Qy=^EsgK`r>SM=F-SUZ3
zA3uKTmfMEiDK<7ijdM3T{YR$vMgzuXOI<gRiCO#5bZh)7f?jn>Z6xz;oNvHudCR)W
zUkEkuFBdw0J5OjDUIn8yWM#z*qas5=@S3Nm*5^QVVt#4l7*J2syjLlBIm~twCBFZY
zIC1ZZzkK4?z-=eKe&RTJ;^>L5oH%~s8*5eztBv=pXmHZsd$cp3vHf+T>n;Nn!YdUj
zMAV-8GvA-YzDMSNM<+G@9)1u%eEZRR;MHFk3<^e@?o~1T65aNR7Iw!l_Bv~iTRz||
z=FoSEHrU5hpIw7db&QB8cy#_-zl?9sJHb|aaS`u6@bY2TBR`^%c~QiDcRN+H%x1-X
a4?L1yO1U-0iF+k=BaZEk;U&*a(*FWE^rH&^

-- 
GitLab


From 4701bcfa3f3c826dd69e53dca2d69a79574aa7a2 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 10:58:16 +0100
Subject: [PATCH 39/46] adds new test for rename method and refactors code for
 the test

---
 CHANGELOG         |  1 +
 spec/blob_spec.rb | 34 +++++++++++++++++++++++++---------
 2 files changed, 26 insertions(+), 9 deletions(-)

diff --git a/CHANGELOG b/CHANGELOG
index aa14f49..0e28697 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,6 +1,7 @@
 v 10.3.0 (unreleased)
   - Remove Repository#format_patch
   - Remove Repository#add_tag
+	- Rename a repository file
 
 v 10.2.3
   - Handle nil blob data
diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 0d89582..42d6e58 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -298,22 +298,35 @@ describe Gitlab::Git::Blob do
       }
     end
 
+    let!(:ref) { commit_options[:commit][:branch] }
+    let!(:prev_commit_count) { repository.commit_count(ref) }
     let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
+    let!(:commit_count) { repository.commit_count(ref) }
+    let!(:blob) {
+      commit.tree.to_a.any? do |tree|
+        tree[:name] == 'NEWREADME.md'
+      end
+    }
+
+    let!(:previous_blob) {
+      commit.tree.to_a.any? do |tree|
+        tree[:name] == 'README.md'
+      end
+    }
 
     it 'should rename the file with commit' do
       # Commit message valid
       expect(commit.message).to eq('Rename readme')
 
+      #Only one commit was made
+      expect(commit_count).to eq(prev_commit_count + 1)
+
       # Previous file was removed
-      expect(commit.tree.to_a.any? do |tree|
-        tree[:name] == 'README.md'
-      end).to be_falsey
+      expect(previous_blob).to be_falsey
 
       # File was renamed
-      expect(commit.tree.to_a.any? do |tree|
-        tree[:name] == 'NEWREADME.md'
-      end).to be_truthy
+      expect(blob).to be_truthy
     end
   end
 
@@ -344,15 +357,18 @@ describe Gitlab::Git::Blob do
 
     let!(:commit_sha) { Gitlab::Git::Blob.remove(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
+    let!(:blob) {
+      commit.tree.to_a.any? do |tree|
+        tree[:name] == "README.md"
+      end
+    }
 
     it 'should remove file with commit' do
       # Commit message valid
       expect(commit.message).to eq('Remove readme')
 
       # File was removed
-      expect(commit.tree.to_a.any? do |tree|
-        tree[:name] == 'README.md'
-      end).to be_falsey
+      expect(blob).to be_falsey
     end
   end
 
-- 
GitLab


From 413aaa19abdb0cf136d25bdbc454ac7d9762af58 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 10:59:29 +0100
Subject: [PATCH 40/46] changes tabs to spaces on CHANGELOG file

---
 CHANGELOG | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/CHANGELOG b/CHANGELOG
index 0e28697..27eef85 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,7 +1,7 @@
 v 10.3.0 (unreleased)
   - Remove Repository#format_patch
   - Remove Repository#add_tag
-	- Rename a repository file
+  - Rename a repository file
 
 v 10.2.3
   - Handle nil blob data
-- 
GitLab


From dcf55d477b01b39b97b8a24592a79d59620d4c38 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 15:01:53 +0100
Subject: [PATCH 41/46] improves codestyle of test

---
 spec/blob_spec.rb | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 42d6e58..f5f372b 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -299,10 +299,8 @@ describe Gitlab::Git::Blob do
     end
 
     let!(:ref) { commit_options[:commit][:branch] }
-    let!(:prev_commit_count) { repository.commit_count(ref) }
     let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
-    let!(:commit_count) { repository.commit_count(ref) }
     let!(:blob) {
       commit.tree.to_a.any? do |tree|
         tree[:name] == 'NEWREADME.md'
@@ -319,8 +317,8 @@ describe Gitlab::Git::Blob do
       # Commit message valid
       expect(commit.message).to eq('Rename readme')
 
-      #Only one commit was made
-      expect(commit_count).to eq(prev_commit_count + 1)
+      # Only one commit was made
+      expect(commit_sha).to change { repository.commit_count(ref) }.by(1)
 
       # Previous file was removed
       expect(previous_blob).to be_falsey
-- 
GitLab


From f1973f951081d4c6f51956d167665e8f048d4645 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 15:16:33 +0100
Subject: [PATCH 42/46] reverts back to old codestyle for rename test

---
 spec/blob_spec.rb | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index f5f372b..42d6e58 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -299,8 +299,10 @@ describe Gitlab::Git::Blob do
     end
 
     let!(:ref) { commit_options[:commit][:branch] }
+    let!(:prev_commit_count) { repository.commit_count(ref) }
     let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
+    let!(:commit_count) { repository.commit_count(ref) }
     let!(:blob) {
       commit.tree.to_a.any? do |tree|
         tree[:name] == 'NEWREADME.md'
@@ -317,8 +319,8 @@ describe Gitlab::Git::Blob do
       # Commit message valid
       expect(commit.message).to eq('Rename readme')
 
-      # Only one commit was made
-      expect(commit_sha).to change { repository.commit_count(ref) }.by(1)
+      #Only one commit was made
+      expect(commit_count).to eq(prev_commit_count + 1)
 
       # Previous file was removed
       expect(previous_blob).to be_falsey
-- 
GitLab


From 6497d2b2038bc822a08dd8cc68d472ce77ba1457 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 16:47:34 +0100
Subject: [PATCH 43/46] fixes issues for MR acceptance

---
 spec/blob_spec.rb | 29 ++++++++++-------------------
 1 file changed, 10 insertions(+), 19 deletions(-)

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 42d6e58..7f4bb00 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -300,33 +300,24 @@ describe Gitlab::Git::Blob do
 
     let!(:ref) { commit_options[:commit][:branch] }
     let!(:prev_commit_count) { repository.commit_count(ref) }
-    let!(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
-    let!(:commit) { repository.lookup(commit_sha) }
-    let!(:commit_count) { repository.commit_count(ref) }
-    let!(:blob) {
-      commit.tree.to_a.any? do |tree|
-        tree[:name] == 'NEWREADME.md'
-      end
-    }
-
-    let!(:previous_blob) {
-      commit.tree.to_a.any? do |tree|
-        tree[:name] == 'README.md'
-      end
-    }
+    let(:commit_sha) { Gitlab::Git::Blob.rename(repository, commit_options) }
+    let(:commit_count) { repository.commit_count(ref) }
+    let(:commit) { repository.lookup(commit_sha) }
+    let(:blob) { Gitlab::Git::Blob.find(repository, commit_sha, "NEWREADME.md") }
+    let(:removed_blob) { Gitlab::Git::Blob.find(repository, commit_sha, "README.md") }
 
     it 'should rename the file with commit' do
       # Commit message valid
       expect(commit.message).to eq('Rename readme')
 
-      #Only one commit was made
+      # Only one commit was made
       expect(commit_count).to eq(prev_commit_count + 1)
 
       # Previous file was removed
-      expect(previous_blob).to be_falsey
+      expect(removed_blob).to be_nil
 
       # File was renamed
-      expect(blob).to be_truthy
+      expect(blob).not_to be_nil
     end
   end
 
@@ -357,11 +348,11 @@ describe Gitlab::Git::Blob do
 
     let!(:commit_sha) { Gitlab::Git::Blob.remove(repository, commit_options) }
     let!(:commit) { repository.lookup(commit_sha) }
-    let!(:blob) {
+    let!(:blob) do
       commit.tree.to_a.any? do |tree|
         tree[:name] == "README.md"
       end
-    }
+    end
 
     it 'should remove file with commit' do
       # Commit message valid
-- 
GitLab


From 27b430632976ec4d594b1600051e3c9250b8e89c Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 16:52:38 +0100
Subject: [PATCH 44/46] adds rubocop-rspec gem

---
 Gemfile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Gemfile b/Gemfile
index 038a3e8..5a896d3 100644
--- a/Gemfile
+++ b/Gemfile
@@ -4,6 +4,7 @@ gemspec
 
 group :development do
   gem 'rubocop'
+  gem 'rubocop-rspec' '~> 1.5.0'
   gem 'coveralls', require: false
   gem 'rspec', '~> 3.0'
   gem 'rspec-mocks'
-- 
GitLab


From c020dda65176578c2d87ee5a02c82bfa53746570 Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 16:54:50 +0100
Subject: [PATCH 45/46] fixes :remove test for remove action

---
 spec/blob_spec.rb | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/spec/blob_spec.rb b/spec/blob_spec.rb
index 7f4bb00..0af42c9 100644
--- a/spec/blob_spec.rb
+++ b/spec/blob_spec.rb
@@ -346,20 +346,16 @@ describe Gitlab::Git::Blob do
       }
     end
 
-    let!(:commit_sha) { Gitlab::Git::Blob.remove(repository, commit_options) }
-    let!(:commit) { repository.lookup(commit_sha) }
-    let!(:blob) do
-      commit.tree.to_a.any? do |tree|
-        tree[:name] == "README.md"
-      end
-    end
+    let(:commit_sha) { Gitlab::Git::Blob.remove(repository, commit_options) }
+    let(:commit) { repository.lookup(commit_sha) }
+    let(:blob) { Gitlab::Git::Blob.find(repository, commit_sha, "README.md") }
 
     it 'should remove file with commit' do
       # Commit message valid
       expect(commit.message).to eq('Remove readme')
 
       # File was removed
-      expect(blob).to be_falsey
+      expect(blob).to be_nil
     end
   end
 
-- 
GitLab


From 02c73c3b20e7144e0b447080b8e92b97d37b329e Mon Sep 17 00:00:00 2001
From: tiagonbotelho <tiagonbotelho@hotmail.com>
Date: Wed, 6 Jul 2016 16:58:31 +0100
Subject: [PATCH 46/46] fixes missing comma

---
 Gemfile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Gemfile b/Gemfile
index 5a896d3..394be07 100644
--- a/Gemfile
+++ b/Gemfile
@@ -4,7 +4,7 @@ gemspec
 
 group :development do
   gem 'rubocop'
-  gem 'rubocop-rspec' '~> 1.5.0'
+  gem 'rubocop-rspec', '~> 1.5.0'
   gem 'coveralls', require: false
   gem 'rspec', '~> 3.0'
   gem 'rspec-mocks'
-- 
GitLab