Skip to content

Commit

Permalink
initial commit of sfdc-namespace-prefix
Browse files Browse the repository at this point in the history
  • Loading branch information
jordanbaucke committed Nov 30, 2011
0 parents commit 6548f5d
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 0 deletions.
52 changes: 52 additions & 0 deletions namespace.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
#
# namespace.rb
# Namingspacing for SFDC
#
# invoke this file from the root of an /src
# directory of a SFDC meta-data project

# parse in the special naming considerations file
# this file contains naming consideration for one off cases
# that need to be updated between a developing org and a
# package org (where certain meta-data cannot be removed)
File.open('namingConsiderations.txt').each{ |line|
puts(line)
}

puts('/****************************************************/');
puts(' Running Namespacing for SFDC Developer Orgs ');
puts('/****************************************************/');

#enter current working directory for SFDC Apex SRC
srcFolderPath = Dir.getwd()
puts('Current source path: '+Dir.getwd())
puts('Current SRC Dir Content: ')
srcFolders = Dir.glob("**/");

srcFolders.each do |srcFolder|
puts(srcFolder)
end


srcFolders.each do |srcFolder|
Dir.chdir(srcFolderPath)
puts('Now entering: '+srcFolder)
Dir.chdir(srcFolder);
srcFiles = Dir.glob('*.{cls,page,object}') #get all source files in that directory
srcFiles.each do |srcFile|
puts(srcFile);

end
end

#
# If the current code has special naming considerations (classnames,objectnames,etc),
# this method will invoke those changes to the file on a case by case basis
#
# The file namingConsiderations.txt will be parsed into an array with the structure:
# array: namingConsiderations[developmentOrgName][packagingOrgName]
#
def checkSrcFileName(filename)
#todo
end

Empty file added readme
Empty file.

0 comments on commit 6548f5d

Please sign in to comment.