diff options
author | B. Stack <bgstack15@gmail.com> | 2022-05-17 21:32:43 -0400 |
---|---|---|
committer | B. Stack <bgstack15@gmail.com> | 2022-05-17 21:32:43 -0400 |
commit | 0d737af02d0b27bb4d9fbb453f09c293036d1a39 (patch) | |
tree | 9eaada241675221ee9129ebd7e1d46519df1fd6e /lib.sh | |
download | build-radicale-el7-0d737af02d0b27bb4d9fbb453f09c293036d1a39.tar.gz build-radicale-el7-0d737af02d0b27bb4d9fbb453f09c293036d1a39.tar.bz2 build-radicale-el7-0d737af02d0b27bb4d9fbb453f09c293036d1a39.zip |
initial commit
Diffstat (limited to 'lib.sh')
-rw-r--r-- | lib.sh | 31 |
1 files changed, 31 insertions, 0 deletions
@@ -0,0 +1,31 @@ +#!/bin/sh +# File: lib.sh +# Author: bgstack15 +# SPDX-License-Identifier: GPL-3.0 +# Startdate: 2022-05-17 +# Title: Library for build-radicale-centos7 +# Project: build-radicale-centos7 +# Purpose: library of common functions and variables +# History: +# Usage: dot-sourced by other scripts here +# Reference: +# Improve: +# Dependencies: +# Documentation: +# README.md + +WORKDIR=~/dev2 +FEDORA_VER=f36 +# COPR username comes from ~/.config/copr auth file +COPR_REPO=radicale-el7 + +get_latest() { + # call: get_latest ~/rpmbuild/SRPMS "python-nose*.src.rpm" + # returns: most-recently-modified python-nose*.src.rpm file + ___gl_path="${1}" + ___gl_pattern="${2}" + ( + cd "${___gl_path}" + basename $( find . -iname "${___gl_pattern}" -exec ls -1t {} + 2>/dev/null | head -n1 ; ) + ) +} |