{"id":198,"date":"2018-11-15T18:07:52","date_gmt":"2018-11-15T17:07:52","guid":{"rendered":"https:\/\/ubuntu.science\/?p=198"},"modified":"2022-04-03T22:23:12","modified_gmt":"2022-04-03T20:23:12","slug":"recherche-de-fichiers-ubuntu","status":"publish","type":"post","link":"https:\/\/rootfan.com\/fr\/find-files-ubuntu\/","title":{"rendered":"Comment trouver des fichiers dans le terminal Ubuntu"},"content":{"rendered":"<p>Voici une liste de commandes que j'utilise pour trouver des fichiers dans Ubuntu.<\/p>\n\n\n\n<p>Pour trouver tous les fichiers portant l'extension .zip, vous pouvez utiliser la m\u00e9thode suivante<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code\" data-no-translation=\"\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nfind . -name \"*.zip\"\n<\/pre><\/div>\n\n\n<p>Si vous souhaitez trouver tous les fichiers contenant un motif, utilisez la m\u00e9thode suivante<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code\" data-no-translation=\"\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nfind . -name \"*pattern*\"\n<\/pre><\/div>\n\n\n<!--more-->\n\n\n\n<p>Si vous souhaitez exclure un r\u00e9pertoire, par exemple dir1, de la recherche, utilisez la commande suivante<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code\" data-no-translation=\"\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nfind . -path .\/dir1 -prune -false -o -name '*.txt'\n<\/pre><\/div>\n\n\n<p>Si vous souhaitez exclure de nombreux r\u00e9pertoires de la recherche, utilisez la commande suivante<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code\" data-no-translation=\"\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nfind . -type d \\( -path dir1 -o -path dir2 -o -path dir3 \\) -prune -false -o -name '*.txt'\n<\/pre><\/div>\n\n\n<p>Si vous voulez <strong>recherche uniquement des fichiers<\/strong> vous devez alors utiliser cette commande.<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code\" data-no-translation=\"\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nfind . -type f -name \"*.zip\"\n<\/pre><\/div>\n\n\n<p>Si vous souhaitez ignorer la casse des lettres, utilisez&nbsp;<strong>iname<\/strong>&nbsp;au lieu de&nbsp;<strong>nom<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code\" data-no-translation=\"\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nfind . -iname \"*pattern*\"\n<\/pre><\/div>\n\n\n<p>Comment trouver les derniers fichiers par date de modification<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code\" data-no-translation=\"\"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nfind . -type f -exec ls -lt \\{\\} \\+ | head\n<\/pre><\/div>","protected":false},"excerpt":{"rendered":"<p>Voici une liste de commandes que j'utilise pour trouver des fichiers dans Ubuntu. Pour trouver tous les fichiers avec l'extension .zip, vous pouvez utiliser ceci Si vous voulez trouver tous les fichiers avec un motif, utilisez ceci<\/p>","protected":false},"author":1,"featured_media":2863,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"rank_math_focus_keyword":"","rank_math_title":"","rank_math_description":"Quickly find files in Ubuntu terminal using simple commands and streamline your file search process.","rank_math_robots":null,"rank_math_og_title":"","rank_math_og_description":"","jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[46],"tags":[8,15,16,29],"class_list":["post-198","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-ubuntu","tag-command","tag-files","tag-find","tag-ubuntu"],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/rootfan.com\/wp-content\/uploads\/pexels-photo-172292.jpeg?fit=1880%2C1251&ssl=1","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/posts\/198","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/comments?post=198"}],"version-history":[{"count":6,"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/posts\/198\/revisions"}],"predecessor-version":[{"id":2865,"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/posts\/198\/revisions\/2865"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/media\/2863"}],"wp:attachment":[{"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/media?parent=198"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/categories?post=198"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rootfan.com\/fr\/wp-json\/wp\/v2\/tags?post=198"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}