summaryrefslogblamecommitdiffstats
path: root/test/dir-a-b.test
blob: 326d482003c5ef978e5fe5bbf16b0269c73f0657 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
                       

                           
                            






                               







                         
 


                                         

                                    















                                     
                               
                                        
                                     















                             
                       
                                    
                            
	$ mkdir patches

	$ echo a > test.txt
	$ echo d > test3.txt

	$ cat > patches/ab.diff
	< --- a/test.txt
	< +++ b/test.txt
	< @@ -1 +1 @@
	< -a
	< +b
	< --- /dev/null
	< +++ b/test2.txt
	< @@ -0,0 +1 @@
	< +c
	< --- a/test3.txt
	< +++ /dev/null
	< @@ -1 +0,0 @@
	< -d

	$ echo "ab.diff" > patches/series

	$ quilt push -q
	> Applying patch %{P}ab.diff
	> Now at patch %{P}ab.diff

	$ quilt diff -p ab --no-index
	> --- a/test.txt
	> +++ b/test.txt
	> @@ -1 +1 @@
	> -a
	> +b
	> --- /dev/null
	> +++ b/test2.txt
	> @@ -0,0 +1 @@
	> +c
	> --- a/test3.txt
	> +++ /dev/null
	> @@ -1 +0,0 @@
	> -d

	$ rm -f patches/ab.diff
	$ quilt refresh -p ab --no-index
	> Refreshed patch %{P}ab.diff

	$ cat patches/ab.diff
	> --- a/test.txt
	> +++ b/test.txt
	> @@ -1 +1 @@
	> -a
	> +b
	> --- /dev/null
	> +++ b/test2.txt
	> @@ -0,0 +1 @@
	> +c
	> --- a/test3.txt
	> +++ /dev/null
	> @@ -1 +0,0 @@
	> -d

	$ quilt pop -qR
	> Removing patch %{P}ab.diff
	> No patches applied