File tmux-resurrect.spec of Package tmux-resurrect

#
# spec file for package tmux-resurrect
#
# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


Name:           tmux-resurrect
Version:        2.4.0
Release:        0%{?dist}
Summary:        Persists tmux environment across system restarts
License:        MIT
Group:          System/Console
URL:            https://github.com/binary-sequence-forks/tmux-resurrect
Source:         %{name}-%{version}.tar.gz
Requires:       bash
Requires:       expect
Requires:       tmux >= 1.9
BuildArch:      noarch

%description
Restore tmux environment after system restart.

In tmux, you lose all the running programs, working directories,
pane layouts, etc. when you restart the computer. There are helpful
management tools out there, but they require initial configuration
and continuous updates as your workflow evolves or you start new projects.

tmux-resurrect saves all the little details from your tmux environment so
it can be completely restored after a system restart (or when you feel like
it). No configuration is required. You should feel like you never quit tmux.

It also (optionally) restores vim and neovim sessions.

Automatic restoring and continuous saving of tmux env is also possible
with tmux-continuum plugin.

%prep
%setup -q
sed -ie "1s,^#!%{_bindir}/env bash,#!%{_bindir}/bash," \
    ./resurrect.tmux \
    save_command_strategies/* \
    scripts/* \
    strategies/* \
    tests/*.sh

sed -ie "1s,^#!%{_bindir}/env expect,#!%{_bindir}/expect," scripts/restore.exp
sed -ie '1s,^,#!/usr/bin/bash\n\n,' \
    scripts/helpers.sh \
    scripts/process_restore_helpers.sh \
    scripts/spinner_helpers.sh \
    scripts/variables.sh


%build
# do nothing

%install
%make_install prefix=%{_prefix} software_srcdir=%{_builddir}/%{name}-%{version}

%files
%{_datadir}/%{name}/
%{_datadir}/%{name}/resurrect.tmux
%{_datadir}/%{name}/save_command_strategies/
%{_datadir}/%{name}/save_command_strategies/gdb.sh
%{_datadir}/%{name}/save_command_strategies/linux_procfs.sh
%{_datadir}/%{name}/save_command_strategies/pgrep.sh
%{_datadir}/%{name}/save_command_strategies/ps.sh
%{_datadir}/%{name}/scripts/
%{_datadir}/%{name}/scripts/check_tmux_version.sh
%{_datadir}/%{name}/scripts/helpers.sh
%{_datadir}/%{name}/scripts/process_restore_helpers.sh
%{_datadir}/%{name}/scripts/restore.exp
%{_datadir}/%{name}/scripts/restore.sh
%{_datadir}/%{name}/scripts/save.sh
%{_datadir}/%{name}/scripts/spinner_helpers.sh
%{_datadir}/%{name}/scripts/tmux_spinner.sh
%{_datadir}/%{name}/scripts/variables.sh
%{_datadir}/%{name}/strategies/
%{_datadir}/%{name}/strategies/irb_default_strategy.sh
%{_datadir}/%{name}/strategies/mosh-client_default_strategy.sh
%{_datadir}/%{name}/strategies/nvim_session.sh
%{_datadir}/%{name}/strategies/vim_session.sh

%changelog
openSUSE Build Service is sponsored by