文件操作 - node.rb
返回文件管理
返回主菜单
删除本文件
文件: /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/parser/ast/node.rb
编辑文件内容
# frozen_string_literal: true class Puppet::Parser::AST::Node < Puppet::Parser::AST::TopLevelConstruct attr_accessor :names, :context def initialize(names, context = {}) raise ArgumentError, _("names should be an array") unless names.is_a? Array if context[:parent] raise Puppet::DevError, _("Node inheritance is removed in Puppet 4.0.0. See http://links.puppet.com/puppet-node-inheritance-deprecation") end @names = names @context = context end def instantiate(modname) @names.map { |name| Puppet::Resource::Type.new(:node, name, @context.merge(:module_name => modname)) } end end
修改文件时间
将文件时间修改为当前时间的前一年
删除文件