Man page copying: only copy .1
- check if possible first
This commit is contained in:
		
							parent
							
								
									fe2162030b
								
							
						
					
					
						commit
						925f6fd3f0
					
				
							
								
								
									
										6
									
								
								Rakefile
									
									
									
									
									
								
							
							
						
						
									
										6
									
								
								Rakefile
									
									
									
									
									
								
							@ -12,10 +12,12 @@ RSpec::Core::RakeTask.new(:rspec)
 | 
			
		||||
task :create_man do |_t|
 | 
			
		||||
  os_prefix = "/usr/local"
 | 
			
		||||
  man_prefix = Pathname("#{os_prefix}/share/man/man1")
 | 
			
		||||
  man_pages = "man/git-*"
 | 
			
		||||
  man_pages = "man/git-*.1"
 | 
			
		||||
 | 
			
		||||
  Pathname.glob(man_pages) do |path|
 | 
			
		||||
    FileUtils.cp(path, man_prefix + path.basename)
 | 
			
		||||
    if path.exist? && man_prefix.exist?
 | 
			
		||||
      FileUtils.cp(path, man_prefix + path.basename)
 | 
			
		||||
    end
 | 
			
		||||
  end
 | 
			
		||||
end
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user