Skip to content

Commit

Permalink
rename DockerFile.dev && check ~/.bashrc exist (#674)
Browse files Browse the repository at this point in the history
* fix: major_hold_scene dmesg get

 add: version check task

* rca disconnection support env  'from' 'to'

* rca disconnection support env  'from' 'to'

* rca disconnection support env  'from' 'to'

* add check core_file is exist by kernel.core_pattern

* update check task: cluster.datafile_next

* rename DockerFile.dev && check ~/.bashrc exist
  • Loading branch information
wayyoungboy authored Jan 9, 2025
1 parent 7121784 commit 1e8e80e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
File renamed without changes.
12 changes: 7 additions & 5 deletions rpm/init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,13 @@ find ${OBDIAG_HOME}/rca -maxdepth 1 -name "*_scene.py" -type f -exec rm -f {} +

cp -rf ${WORK_DIR}/plugins/* ${OBDIAG_HOME}/


ALIAS_OBDIAG_EXIST=$(grep "alias obdiag='sh" ~/.bashrc | head -n 1)
if [[ "${ALIAS_OBDIAG_EXIST}" != "" ]]; then
echo "need update obdiag alias"
echo "alias obdiag='obdiag'" >> ~/.bashrc
bashrc_file=~/.bashrc
if [ -e "$bashrc_file" ]; then
ALIAS_OBDIAG_EXIST=$(grep "alias obdiag='sh" ~/.bashrc | head -n 1)
if [[ "${ALIAS_OBDIAG_EXIST}" != "" ]]; then
echo "need update obdiag alias"
echo "alias obdiag='obdiag'" >> ~/.bashrc
fi
fi

source ${WORK_DIR}/init_obdiag_cmd.sh
Expand Down

0 comments on commit 1e8e80e

Please sign in to comment.