Return-Path: X-Original-To: apmail-karaf-issues-archive@minotaur.apache.org Delivered-To: apmail-karaf-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id D3ED611293 for ; Mon, 4 Aug 2014 15:26:12 +0000 (UTC) Received: (qmail 47256 invoked by uid 500); 4 Aug 2014 15:26:12 -0000 Delivered-To: apmail-karaf-issues-archive@karaf.apache.org Received: (qmail 47228 invoked by uid 500); 4 Aug 2014 15:26:12 -0000 Mailing-List: contact issues-help@karaf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@karaf.apache.org Delivered-To: mailing list issues@karaf.apache.org Received: (qmail 47215 invoked by uid 99); 4 Aug 2014 15:26:12 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 04 Aug 2014 15:26:12 +0000 Date: Mon, 4 Aug 2014 15:26:12 +0000 (UTC) From: "Dmitry Konstantinov (JIRA)" To: issues@karaf.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (KARAF-3148) Extract common part of karaf bin scripts to a separate file to avoid duplication MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/KARAF-3148?page=3Dcom.atlassian= .jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1408= 4769#comment-14084769 ]=20 Dmitry Konstantinov commented on KARAF-3148: -------------------------------------------- For example: detectOS() { # OS specific support (must be 'true' or 'false'). cygwin=3Dfalse; darwin=3Dfalse; aix=3Dfalse; os400=3Dfalse; case "`uname`" in CYGWIN*) cygwin=3Dtrue ;; Darwin*) darwin=3Dtrue ;; AIX*) aix=3Dtrue ;; OS400*) os400=3Dtrue ;; esac # For AIX, set an environment variable if $aix; then export LDR_CNTRL=3DMAXDATA=3D0xB0000000@DSA echo $LDR_CNTRL fi }=20 I found the definition in stop, start, karaf, status, shell, instance, clie= nt scripts. > Extract common part of karaf bin scripts to a separate file to avoid dupl= ication > -------------------------------------------------------------------------= ------- > > Key: KARAF-3148 > URL: https://issues.apache.org/jira/browse/KARAF-3148 > Project: Karaf > Issue Type: Improvement > Affects Versions: 3.0.1, 2.3.6 > Reporter: Dmitry Konstantinov > Assignee: Jean-Baptiste Onofr=C3=A9 > Priority: Minor > > It make sense to extract the following functions to a separate file and r= euse them: > # Determine if there is special OS handling we must perform > detectOS > # Unlimit the number of file descriptors if possible > unlimitFD > # Locate the Karaf home directory > locateHome > # Locate the Karaf base directory > locateBase > # Locate the Karaf data directory > locateData > # Setup the native library path > setupNativePath > # Locate the Java VM to execute > locateJava > # Determine the JVM vendor > detectJVM > # Setup default options > setupDefaults -- This message was sent by Atlassian JIRA (v6.2#6252)