Imported from SRPM

This commit is contained in:
Sergey Zhemoytel 2022-12-15 18:04:02 +03:00
commit 5ac3aa8da2
2 changed files with 57 additions and 0 deletions

2
.abf.yml Normal file
View file

@ -0,0 +1,2 @@
sources:
usql-0.13.1.tar.gz: 77a6abcc1a61908365e1b8d3e723fe8c7c19e0c5

55
usql.spec Normal file
View file

@ -0,0 +1,55 @@
%define debug %nil
%define debug_package %nil
Name: usql
Version: 0.13.1
Release: 1
Summary: Universal command-line interface for SQL databases
URL: https://github.com/xo/usql
Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz
License: MIT
Group: Development/Other
BuildRequires: go
BuildRequires: git-core
BuildRequires: upx
%description
usql is a universal command-line interface for PostgreSQL,
MySQL, Oracle Database, SQLite3, Microsoft SQL Server,
and many other databases including NoSQL and non-relational
databases!
usql provides a simple way to work with SQL and NoSQL
databases via a command-line inspired by PostgreSQL's psql.
usql supports most of the core psql features, such as
variables, backticks, backslash commands and has additional
features that psql does not, such as multiple database
support, copying between databases, syntax highlighting,
and context-based completion.
Database administrators and developers that would prefer
to work with a tool like psql with non-PostgreSQL databases,
will find usql intuitive, easy-to-use, and a great
replacement for the command-line clients/tools for other
databases.
%prep
%setup -q
%build
#define LDFLAGS `"-s -w -X github.com/xo/usql/text.CommandName=%{name} -X github.com/xo/usql/text.CommandVersion=%{version}"`
go build -ldflags="-s -w -X github.com/xo/usql/text.CommandName=%{name} -X github.com/xo/usql/text.CommandVersion=%{version}" -trimpath -o bin/%{name}
upx bin/%{name}
%install
install -Dm0755 bin/%{name} %{buildroot}%{_bindir}/%{name}
%files
%doc README.md LICENSE
%{_bindir}/%{name}