Sha256: a20454c1cc82e86915196a42404408a65218a6f177eef3eb6d141cf48dd91d61

Contents?: true

Size: 1.45 KB

Versions: 68

Compression:

Stored size: 1.45 KB

Contents

# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with this
# work for additional information regarding copyright ownership. The ASF
# licenses this file to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations under
# the License.

module Buildr

  # A simple extension that modifies the project layout to place generated files at the top level.
  # Generated files are typically created below layout[:target, :generated], placing them at the top
  # level makes it easy for IDEs to inspect source in the generated directory while ignoring the dir
  # containing the intermediate artifacts.
  #
  module TopLevelGenerateDir
    module ProjectExtension
      include Extension

      before_define do |project|
        project.layout[:target, :generated] = "generated"
        project.clean { rm_rf project._(:target, :generated) }
      end
    end
  end
end

class Buildr::Project
  include Buildr::TopLevelGenerateDir::ProjectExtension
end

Version data entries

68 entries across 68 versions & 2 rubygems

Version Path
buildr-1.5.2 addon/buildr/top_level_generate_dir.rb
buildr-1.5.2-x86-mswin32 addon/buildr/top_level_generate_dir.rb
buildr-1.5.2-java addon/buildr/top_level_generate_dir.rb
buildr-1.5.1 addon/buildr/top_level_generate_dir.rb
buildr-1.5.1-x86-mswin32 addon/buildr/top_level_generate_dir.rb
buildr-1.5.1-java addon/buildr/top_level_generate_dir.rb
buildr-1.5.0 addon/buildr/top_level_generate_dir.rb
buildr-1.5.0-x86-mswin32 addon/buildr/top_level_generate_dir.rb
buildr-1.5.0-java addon/buildr/top_level_generate_dir.rb
buildr-1.5.0.dev3-x86-mswin32 addon/buildr/top_level_generate_dir.rb
buildr-1.5.0.dev3 addon/buildr/top_level_generate_dir.rb
buildr-1.5.0.dev3-java addon/buildr/top_level_generate_dir.rb
buildr-1.5.0.dev2 addon/buildr/top_level_generate_dir.rb
buildr-1.5.0.dev2-java addon/buildr/top_level_generate_dir.rb
buildr-1.5.0.dev2-x86-mswin32 addon/buildr/top_level_generate_dir.rb
buildr-1.4.25 addon/buildr/top_level_generate_dir.rb
buildr-1.4.25-x86-mswin32 addon/buildr/top_level_generate_dir.rb
buildr-1.4.25-java addon/buildr/top_level_generate_dir.rb
buildr-1.4.24 addon/buildr/top_level_generate_dir.rb
buildr-1.4.24-x86-mswin32 addon/buildr/top_level_generate_dir.rb