文件操作 - typing.py
返回文件管理
返回主菜单
删除本文件
文件: /usr/lib/python3.12/site-packages/ansible/module_utils/compat/typing.py
编辑文件内容
"""Compatibility layer for the `typing` module, providing all Python versions access to the newest type-hinting features.""" from __future__ import (absolute_import, division, print_function) __metaclass__ = type # pylint: disable=wildcard-import,unused-wildcard-import # catch *all* exceptions to prevent type annotation support module bugs causing runtime failures # (eg, https://github.com/ansible/ansible/issues/77857) try: from typing_extensions import * except Exception: # pylint: disable=broad-except pass try: from typing import * # type: ignore[assignment,no-redef] except Exception: # pylint: disable=broad-except pass try: cast # type: ignore[used-before-def] except NameError: def cast(typ, val): # type: ignore[no-redef] return val
修改文件时间
将文件时间修改为当前时间的前一年
删除文件