get last dirname/filename in a file path argument
$ dirname /home/train/00.incipient_data/data_for_gene_prediction_and_RNA-seq/240_rep2.fastq
/home/train/00.incipient_data/data_for_gene_prediction_and_RNA-seq
$ basename /home/train/00.incipient_data/data_for_gene_prediction_and_RNA-seq/240_rep2.fastq
240_rep2.fastq
reference
http://stackoverflow.com/questions/6121091/get-file-directory-path-from-filepath
http://stackoverflow.com/questions/3294072/bash-get-last-dirname-filename-in-a-file-path-argument
http://unix.stackexchange.com/questions/164125/stripping-directory-paths-to-get-file-names
http://www.unix.com/unix-for-dummies-questions-and-answers/2450-extract-only-file-name-full-path-file-name.html
get last dirname/filename in a file path argument的更多相关文章
- Leetcode算法比赛----Longest Absolute File Path
问题描述 Suppose we abstract our file system by a string in the following manner: The string "dir\n ...
- [LeetCode] Longest Absolute File Path 最长的绝对文件路径
Suppose we abstract our file system by a string in the following manner: The string "dir\n\tsub ...
- Longest Absolute File Path
Suppose we abstract our file system by a string in the following manner: The string "dir\n\tsub ...
- Leetcode: Longest Absolute File Path
Suppose we abstract our file system by a string in the following manner: The string "dir\n\tsub ...
- "make_path" is not exported by the File::Path modul
之前正常运行的perl脚本换了一个环境突然报 从原来的make_path 和 remove_tree改为现在的mkpath 和 rmtree就好了. File::Path version is 1.0 ...
- windbg Symbol file path
SOS是一个调试器扩展,用于调试.NET应用程序.它提供了一组非常丰富的命令,这些命令使开发人员可以对CLR进行深入分析,并且有助于找出应用程序中各种复杂错误的原因. 由于SOS能够提供CLR内部 ...
- [Swift]LeetCode388. 文件的最长绝对路径 | Longest Absolute File Path
Suppose we abstract our file system by a string in the following manner: The string "dir\n\tsub ...
- vue-cli 报Module build failed: Error: No parser and no file path given, couldn't infer a parser.错的解决方法
出错提示如下: ERROR Failed to compile with errors :: error in ./src/App.vue Module build failed: Error: No ...
- vue.js报错:Module build failed: Error: No parser and no file path given, couldn't infer a parser.
ERROR Failed to compile with 2 errors 12:00:33 error in ./src/App.vue Module build failed: Error: No ...
随机推荐
- (六)Maven之pom.xml文件简单说明
通过前面几部分知识,我们对maven已经有了初步的印象,就像Make的Makefile.Ant的build.xml一样,Maven项目的核心是pom.xml.POM(Project Object Mo ...
- 比Ansible更吊的自动化运维工具,自动化统一安装部署_自动化部署udeploy 1.0
新增功能: 2015-03-11 除pass(备份与更新)与start(启动服务)外,实现一切自动化. 注:pass与start设为业务类,由于各类业务不同,所以无法实现自动化.同类业务除外,如更新的 ...
- Spring实现AOP的4种方式
了解AOP的相关术语:1.通知(Advice):通知定义了切面是什么以及何时使用.描述了切面要完成的工作和何时需要执行这个工作.2.连接点(Joinpoint):程序能够应用通知的一个“时机”,这些“ ...
- SQL SERVER 属性OWNER不可用于数据库xxx。该对象可能没有此属性,也可能是访问权限不足而无法检索。
今天遇到一个案例:右键单击数据库的属性时出现下面错误提示: 属性Owner不可用于数据库xxx,该对象可能没有此属性,也可能是访问权限不足而无法检索. 使用脚本查看该数据库的Owner时发现Owner ...
- MySQL(三)
MYSQL(三) 上一章给大家说的是数据库的视图,存储过程等等操作,这章主要讲索引,以及索引注意事项,如果想看前面的文章,url如下: MYSQL入门全套(第一部) MYSQL入门全套(第二部) 索引 ...
- PostgreSQL-PL/pgSQL
参考: https://wiki.postgresql.org/wiki/9.1%E7%AC%AC%E4%B8%89%E5%8D%81%E4%B9%9D%E7%AB%A0 摘记: PL/pgSQL是 ...
- send+recv注意事项
[TOC] send 函数原型 ssize_t send( SOCKET s, const char *buf, size_t len, int flags ) 注意事项 待发送数据长度data_le ...
- Linux 多线程可重入函数
Reentrant和Thread-safe 在单线程程序中,整个程序都是顺序执行的,一个函数在同一时刻只能被一个函数调用,但在多线程中,由于并发性,一个函数可能同时被多个函数调用,此时这个函数就成了临 ...
- 【转载】Markdown使用笔记
献给写作者的 Markdown 新手指南 http://www.jianshu.com/p/q81RER 「简书」作为一款「写作软件」在诞生之初就支持了 Markdown,Markdown 是一种「电 ...
- centos 进度条卡死
CentOS 6.7 系统 在执行完删除更新包的全部操作之后, yum remove -y Deployment_Guide-en-US finger cups-libs cups ypbind &a ...