Project

General

Profile

Actions

Issue #1831

open

Fix non-idempotent setup.sh

Added by Jeremy Rand about 7 years ago. Updated over 3 years ago.

Status:
New
Priority:
Normal
Category:
Wi-Fi
Target version:
-
Start date:
09/10/2017
Due date:
% Done:

0%

Estimated time:
Resolution:
Device:
Grant:
Type of work:
Any programming languages (scripts, C, etc), Unknown

Description

The setup.sh scripts in user-scripts aren't idempotent; they install to a different path depending on whether they were previously installed. Attached is a patch that fixes this.


Files

6.0-repeat-setup.patch (1.1 KB) 6.0-repeat-setup.patch Jeremy Rand, 09/10/2017 08:05 AM
Actions #1

Updated by Jeremy Rand almost 7 years ago

  • Assignee set to Wolfgang Wiedmeyer

Hi Wolfgang, any chance you could review this patch? Thanks.

Actions #2

Updated by Kurtis Hanna about 6 years ago

I don't quite understand this issue. Can you explain it a bit more Jeremy?

Actions #3

Updated by Jeremy Rand about 6 years ago

Kurtis Hanna wrote:

I don't quite understand this issue. Can you explain it a bit more Jeremy?

An idempotent script is defined as a script that does the same thing when run twice as when run once. For example, if you run an installer twice, the 2nd time you run it shouldn't change anything since it's already installed. All installer scripts should be idempotent.

Unfortunately, the install scripts in user-scripts are not idempotent. The first time you install it, it installs to a different directory than the second time you install it. This can cause user confusion, e.g. if the user runs the installer, and then tries to later install a newer version, the older and newer versions will both be simultaneously installed (and the path that the user is accustomed to using will still be running the old version).

This patch fixes the issue by making sure that the first installation always installs to the same directory as any subsequent installations.

Actions #4

Updated by Kurtis Hanna about 6 years ago

  • Target version changed from Replicant 6.0 to Replicant 6.0 0005
Actions #5

Updated by Fil Bergamo almost 6 years ago

  • Target version deleted (Replicant 6.0 0005)

This issue does not involve the Replicant tree, but the user-contributed scripts.
As such, it should not be considered part of the roadmap to next Replicant release.
Removed target version.

Actions #6

Updated by _I3^ RELATIVISM over 3 years ago

  • Type of work Any programming languages (scripts, C, etc), Unknown added
Actions

Also available in: Atom PDF