makepkg: remove extra ansi color codes

All those extra '\e[1;'s were just setting bold redundantly or
immediately being cancelled.

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
makepkg: avoid file|grep dependency for CRLF check

Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
pmpkg: default mode 0755 for dirs in sync packages

TarInfo objects default to mode 0644 while mkfile in util.py uses 0755
for directories, causing pacman warnings about differing permissions on
tests involving package updates.  Set the mode on TarInfo directory
objects to 0755 unless the test specifies a different mode.

Bug referenced in FS#30723.

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
util.py: replace file() with open()

open() is the standard way to open a file in python.

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
use off_t for table_row_t.size

size went from off_t in _display_targets to int in
add_transaction_sizes and back to off_t in humanize_size
leading to potential overflows.

Fixes FS#34616.

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
doc: fix debug spelling mistake

with -> when

Signed-off-by: William Giokas <1007380@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
ctypes.h shouldn't be included twice

Earnestly spotted this on #archlinux.

Signed-off-by: Simon Gomizelj <simongmzlj@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
zsh completion: make sure -Ss works

if you put a type in pacman -Ss <regex> it doesn't work because it never
passes through they pointer ->sync_search to set $state.  All of the
other iterations like this have a case, add one for -S*s*

Signed-off-by: Allan McRae <allan@archlinux.org>
Mark string as translatable

Signed-off-by: Allan McRae <allan@archlinux.org>
contrib: Use sysconfdir instead of /etc

Don't force people to see /etc.

Signed-off-by: William Giokas <1007380@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
pacman: add -Qkk to usage() help

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
More verbose bzr branching error

Currently, you can pull bzr repos using different URLs like "lp:"
"http://" or "https://" in the source array. This works well the first
time, but when you want to build the package again and update the local
repo, makepkg will run 'bzr config parent_location' to check if the
local repo is the same as the distant one. Except the reported URL is
generally not the one used in the source array (which is valid
nonetheless) and will fail with a non helpful error message. This patch
makes makepkg print the correct reported URL so that it can be manually
changed in the source array. I, and Gary van der Merwe who wrote the bzr
support, realize this may not be the best approach as it prevents people
from using the convenient "lp:" URLs, but for the time being people will
stop wondering why their valid URLs are rejected.

Signed-off-by: Maxime Gauduin <alucryd@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>