判断/data/www/logs/wos_log/crontab_log是否,

如果不存在则新建

if [ ! -d "/data/www/logs/wos_log/crontab_log" ];then
    mkdir /data/www/logs/wos_log/crontab_log
fi

shell 判断目录是否存在的更多相关文章

  1. linux bash shell 判断目录是否为空的函数

    #!/bin/sh ##方法一 判断输出字符数统计为0 is_empty_dir(){ |wc -w` } ##方法二 判断输出string为空 #is_empty_dir(){ # ` ] #} t ...

  2. shell 判断文件、目录是否存在

    shell判断文件是否存在   1. shell判断文件,目录是否存在或者具有权限 2. #!/bin/sh 3. 4. myPath="/var/log/httpd/" 5. m ...

  3. shell判断文件,目录是否存在或者具有权限的代码

    核心代码 #!/bin/sh myPath="/var/log/httpd/" myFile="/var /log/httpd/access.log" #这里的 ...

  4. shell判断文件,目录是否存在或者具有权限 (转载)

    转自:http://cqfish.blog.51cto.com/622299/187188 文章来源:http://hi.baidu.com/haigang/blog/item/e5f582262d6 ...

  5. shell判断文件,目录是否存在或者具有权限

    shell判断文件,目录是否存在或者具有权限  #!/bin/sh  myPath="/var/log/httpd/"  myFile="/var /log/httpd/ ...

  6. shell判断文件/目录是否存在

    https://www.cnblogs.com/37yan/p/6962563.html caution!!! if should be end with fi caution!!! there sh ...

  7. shell判断文件是否存在

    转自:http://www.cnblogs.com/sunyubo/archive/2011/10/17/2282047.html 1. shell判断文件,目录是否存在或者具有权限 2. #!/bi ...

  8. Linux shell判断文件和文件夹是否存在

    shell判断文件,目录是否存在或者具有权限 #!/bin/sh myPath="/var/log/httpd/" myFile="/var /log/httpd/acc ...

  9. shell判断条件是否存在

    1. shell判断文件,目录是否存在或者具有权限 2. #!/bin/sh 3. 4. myPath="/var/log/httpd/" 5. myFile="/var ...

随机推荐

  1. python3.7中asyncio的具体实现

    讲讲我在使用python异步IO语法时踩过的坑 简单介绍异步IO的原理 以及利用最新语法糖实现异步IO的步骤, 然后给出实现异步的不同例子 网上找了很多python的asyncio示例.很多都是用 # ...

  2. Solr 7.7.0 部署到Tomcat

    第一步 1.Solr 解压后server/solr-webapp下一个webapp目录,它就是Solr的Web项目,把它复制到tomcat的webapps目录下并改名为solr # 进入Solr的se ...

  3. scrapy基础 之 爬虫入门:先用urllib2来理解爬虫

    1,概念理解 爬虫:抓取和保存网页信息,用户看到的网页实质是由 HTML 代码构成的,爬虫爬来的便是这些内容,通过分析和过滤这些 HTML 代码,实现对图片文字等资源的获取. URL:即统一资源定位符 ...

  4. python,练习乌龟吃鱼

    ''' 1.首先要有一个画布 2.随机乌龟和鱼的位置 3.移动 ''' import random as r list_x = [0,10] list_y = [0,10] class Turtle: ...

  5. Debian 9 strech 安装 ROS lunar

    1. 配置源 按照我以前的博客配置或者按照wiki上的配置. 2. sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(ls ...

  6. GPU Tips

    <1> Basic #include <stdio.h> #include <cuda_runtime.h> #include <device_launch_ ...

  7. 使用 ffmpeg nginx rtmp 搭建实时流处理平台

    环境: ubuntu 16.04 问题引入: 使用 opencv 获取摄像头数据帧, 进行处理之后(如进行 keypoint 识别), 将 opencv 中图像的 Mat类型转化为 ffmpeg 的 ...

  8. uniGUI -- Web 应用框架 Delphi + Ext JS

    uniGUI --  Web 应用框架 ,基于 Delphi + Ext JS  技术.

  9. Python3学习笔记30-datetime模块

    datetime是Python处理日期和时间的标准库 获取当前的日期和时间 from datetime import datetime now = datetime.now() print(now) ...

  10. 深度神经网络(DNN)是否模拟了人类大脑皮层结构?

    原文地址:https://www.zhihu.com/question/59800121/answer/184888043 神经元 在深度学习领域,神经元是最底层的单元,如果用感知机的模型, wx + ...